// Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with
// the License. You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on
// an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the
// specific language governing permissions and limitations under the License.

//------------------------------------------------------------------------------
// <auto-generated>
//     This code was generated by google-apis-code-generator 1.5.1
//     C# generator version: 1.22.0
//
//     Changes to this file may cause incorrect behavior and will be lost if
//     the code is regenerated.
// </auto-generated>
//------------------------------------------------------------------------------

/**
 * \brief
 *   Google Play Game Services API Version v1
 *
 * \section ApiInfo API Version Information
 *    <table>
 *      <tr><th>API
 *          <td><a href='https://developers.google.com/games/services/'>Google Play Game Services API</a>
 *      <tr><th>API Version<td>v1
 *      <tr><th>API Rev<td>20170316 (805)
 *      <tr><th>API Docs
 *          <td><a href='https://developers.google.com/games/services/'>
 *              https://developers.google.com/games/services/</a>
 *      <tr><th>Discovery Name<td>games
 *    </table>
 *
 * \section ForMoreInfo For More Information
 *
 * The complete API documentation for using Google Play Game Services API can be found at
 * <a href='https://developers.google.com/games/services/'>https://developers.google.com/games/services/</a>.
 *
 * For more information about the Google APIs Client Library for .NET, see
 * <a href='https://developers.google.com/api-client-library/dotnet/get_started'>
 * https://developers.google.com/api-client-library/dotnet/get_started</a>
 */

namespace Google.Apis.Games.v1
{
    /// <summary>The Games Service.</summary>
    public class GamesService : Google.Apis.Services.BaseClientService
    {
        /// <summary>The API version.</summary>
        public const string Version = "v1";

        /// <summary>The discovery version used to generate this service.</summary>
        public static Google.Apis.Discovery.DiscoveryVersion DiscoveryVersionUsed =
            Google.Apis.Discovery.DiscoveryVersion.Version_1_0;

        /// <summary>Constructs a new service.</summary>
        public GamesService() :
            this(new Google.Apis.Services.BaseClientService.Initializer()) {}

        /// <summary>Constructs a new service.</summary>
        /// <param name="initializer">The service initializer.</param>
        public GamesService(Google.Apis.Services.BaseClientService.Initializer initializer)
            : base(initializer)
        {
            achievementDefinitions = new AchievementDefinitionsResource(this);
            achievements = new AchievementsResource(this);
            applications = new ApplicationsResource(this);
            events = new EventsResource(this);
            leaderboards = new LeaderboardsResource(this);
            metagame = new MetagameResource(this);
            players = new PlayersResource(this);
            pushtokens = new PushtokensResource(this);
            questMilestones = new QuestMilestonesResource(this);
            quests = new QuestsResource(this);
            revisions = new RevisionsResource(this);
            rooms = new RoomsResource(this);
            scores = new ScoresResource(this);
            snapshots = new SnapshotsResource(this);
            turnBasedMatches = new TurnBasedMatchesResource(this);
        }

        /// <summary>Gets the service supported features.</summary>
        public override System.Collections.Generic.IList<string> Features
        {
            get { return new string[0]; }
        }

        /// <summary>Gets the service name.</summary>
        public override string Name
        {
            get { return "games"; }
        }

        /// <summary>Gets the service base URI.</summary>
        public override string BaseUri
        {
            get { return "https://www.googleapis.com/games/v1/"; }
        }

        /// <summary>Gets the service base path.</summary>
        public override string BasePath
        {
            get { return "games/v1/"; }
        }

        /// <summary>Available OAuth 2.0 scopes for use with the Google Play Game Services API.</summary>
        public class Scope
        {
            /// <summary>View and manage its own configuration data in your Google Drive</summary>
            public static string DriveAppdata = "https://www.googleapis.com/auth/drive.appdata";

            /// <summary>Share your Google+ profile information and view and manage your game activity</summary>
            public static string Games = "https://www.googleapis.com/auth/games";

            /// <summary>Know the list of people in your circles, your age range, and language</summary>
            public static string PlusLogin = "https://www.googleapis.com/auth/plus.login";

        }



        private readonly AchievementDefinitionsResource achievementDefinitions;

        /// <summary>Gets the AchievementDefinitions resource.</summary>
        public virtual AchievementDefinitionsResource AchievementDefinitions
        {
            get { return achievementDefinitions; }
        }

        private readonly AchievementsResource achievements;

        /// <summary>Gets the Achievements resource.</summary>
        public virtual AchievementsResource Achievements
        {
            get { return achievements; }
        }

        private readonly ApplicationsResource applications;

        /// <summary>Gets the Applications resource.</summary>
        public virtual ApplicationsResource Applications
        {
            get { return applications; }
        }

        private readonly EventsResource events;

        /// <summary>Gets the Events resource.</summary>
        public virtual EventsResource Events
        {
            get { return events; }
        }

        private readonly LeaderboardsResource leaderboards;

        /// <summary>Gets the Leaderboards resource.</summary>
        public virtual LeaderboardsResource Leaderboards
        {
            get { return leaderboards; }
        }

        private readonly MetagameResource metagame;

        /// <summary>Gets the Metagame resource.</summary>
        public virtual MetagameResource Metagame
        {
            get { return metagame; }
        }

        private readonly PlayersResource players;

        /// <summary>Gets the Players resource.</summary>
        public virtual PlayersResource Players
        {
            get { return players; }
        }

        private readonly PushtokensResource pushtokens;

        /// <summary>Gets the Pushtokens resource.</summary>
        public virtual PushtokensResource Pushtokens
        {
            get { return pushtokens; }
        }

        private readonly QuestMilestonesResource questMilestones;

        /// <summary>Gets the QuestMilestones resource.</summary>
        public virtual QuestMilestonesResource QuestMilestones
        {
            get { return questMilestones; }
        }

        private readonly QuestsResource quests;

        /// <summary>Gets the Quests resource.</summary>
        public virtual QuestsResource Quests
        {
            get { return quests; }
        }

        private readonly RevisionsResource revisions;

        /// <summary>Gets the Revisions resource.</summary>
        public virtual RevisionsResource Revisions
        {
            get { return revisions; }
        }

        private readonly RoomsResource rooms;

        /// <summary>Gets the Rooms resource.</summary>
        public virtual RoomsResource Rooms
        {
            get { return rooms; }
        }

        private readonly ScoresResource scores;

        /// <summary>Gets the Scores resource.</summary>
        public virtual ScoresResource Scores
        {
            get { return scores; }
        }

        private readonly SnapshotsResource snapshots;

        /// <summary>Gets the Snapshots resource.</summary>
        public virtual SnapshotsResource Snapshots
        {
            get { return snapshots; }
        }

        private readonly TurnBasedMatchesResource turnBasedMatches;

        /// <summary>Gets the TurnBasedMatches resource.</summary>
        public virtual TurnBasedMatchesResource TurnBasedMatches
        {
            get { return turnBasedMatches; }
        }
    }

    ///<summary>A base abstract class for Games requests.</summary>
    public abstract class GamesBaseServiceRequest<TResponse> : Google.Apis.Requests.ClientServiceRequest<TResponse>
    {
        ///<summary>Constructs a new GamesBaseServiceRequest instance.</summary>
        protected GamesBaseServiceRequest(Google.Apis.Services.IClientService service)
            : base(service)
        {
        }

        /// <summary>Data format for the response.</summary>
        /// [default: json]
        [Google.Apis.Util.RequestParameterAttribute("alt", Google.Apis.Util.RequestParameterType.Query)]
        public virtual System.Nullable<AltEnum> Alt { get; set; }

        /// <summary>Data format for the response.</summary>
        public enum AltEnum
        {
            /// <summary>Responses with Content-Type of application/json</summary>
            [Google.Apis.Util.StringValueAttribute("json")]
            Json,
        }

        /// <summary>Selector specifying which fields to include in a partial response.</summary>
        [Google.Apis.Util.RequestParameterAttribute("fields", Google.Apis.Util.RequestParameterType.Query)]
        public virtual string Fields { get; set; }

        /// <summary>API key. Your API key identifies your project and provides you with API access, quota, and reports.
        /// Required unless you provide an OAuth 2.0 token.</summary>
        [Google.Apis.Util.RequestParameterAttribute("key", Google.Apis.Util.RequestParameterType.Query)]
        public virtual string Key { get; set; }

        /// <summary>OAuth 2.0 token for the current user.</summary>
        [Google.Apis.Util.RequestParameterAttribute("oauth_token", Google.Apis.Util.RequestParameterType.Query)]
        public virtual string OauthToken { get; set; }

        /// <summary>Returns response with indentations and line breaks.</summary>
        /// [default: true]
        [Google.Apis.Util.RequestParameterAttribute("prettyPrint", Google.Apis.Util.RequestParameterType.Query)]
        public virtual System.Nullable<bool> PrettyPrint { get; set; }

        /// <summary>Available to use for quota purposes for server-side applications. Can be any arbitrary string
        /// assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.</summary>
        [Google.Apis.Util.RequestParameterAttribute("quotaUser", Google.Apis.Util.RequestParameterType.Query)]
        public virtual string QuotaUser { get; set; }

        /// <summary>IP address of the site where the request originates. Use this if you want to enforce per-user
        /// limits.</summary>
        [Google.Apis.Util.RequestParameterAttribute("userIp", Google.Apis.Util.RequestParameterType.Query)]
        public virtual string UserIp { get; set; }

        /// <summary>Initializes Games parameter list.</summary>
        protected override void InitParameters()
        {
            base.InitParameters();

            RequestParameters.Add(
                "alt", new Google.Apis.Discovery.Parameter
                {
                    Name = "alt",
                    IsRequired = false,
                    ParameterType = "query",
                    DefaultValue = "json",
                    Pattern = null,
                });
            RequestParameters.Add(
                "fields", new Google.Apis.Discovery.Parameter
                {
                    Name = "fields",
                    IsRequired = false,
                    ParameterType = "query",
                    DefaultValue = null,
                    Pattern = null,
                });
            RequestParameters.Add(
                "key", new Google.Apis.Discovery.Parameter
                {
                    Name = "key",
                    IsRequired = false,
                    ParameterType = "query",
                    DefaultValue = null,
                    Pattern = null,
                });
            RequestParameters.Add(
                "oauth_token", new Google.Apis.Discovery.Parameter
                {
                    Name = "oauth_token",
                    IsRequired = false,
                    ParameterType = "query",
                    DefaultValue = null,
                    Pattern = null,
                });
            RequestParameters.Add(
                "prettyPrint", new Google.Apis.Discovery.Parameter
                {
                    Name = "prettyPrint",
                    IsRequired = false,
                    ParameterType = "query",
                    DefaultValue = "true",
                    Pattern = null,
                });
            RequestParameters.Add(
                "quotaUser", new Google.Apis.Discovery.Parameter
                {
                    Name = "quotaUser",
                    IsRequired = false,
                    ParameterType = "query",
                    DefaultValue = null,
                    Pattern = null,
                });
            RequestParameters.Add(
                "userIp", new Google.Apis.Discovery.Parameter
                {
                    Name = "userIp",
                    IsRequired = false,
                    ParameterType = "query",
                    DefaultValue = null,
                    Pattern = null,
                });
        }
    }

    /// <summary>The "achievementDefinitions" collection of methods.</summary>
    public class AchievementDefinitionsResource
    {
        private const string Resource = "achievementDefinitions";

        /// <summary>The service which this resource belongs to.</summary>
        private readonly Google.Apis.Services.IClientService service;

        /// <summary>Constructs a new resource.</summary>
        public AchievementDefinitionsResource(Google.Apis.Services.IClientService service)
        {
            this.service = service;

        }


        /// <summary>Lists all the achievement definitions for your application.</summary>
        public virtual ListRequest List()
        {
            return new ListRequest(service);
        }

        /// <summary>Lists all the achievement definitions for your application.</summary>
        public class ListRequest : GamesBaseServiceRequest<Google.Apis.Games.v1.Data.AchievementDefinitionsListResponse>
        {
            /// <summary>Constructs a new List request.</summary>
            public ListRequest(Google.Apis.Services.IClientService service)
                : base(service)
            {
                InitParameters();
            }


            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }

            /// <summary>The preferred language to use for strings returned by this method.</summary>
            [Google.Apis.Util.RequestParameterAttribute("language", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string Language { get; set; }

            /// <summary>The maximum number of achievement resources to return in the response, used for paging. For any
            /// response, the actual number of achievement resources returned may be less than the specified
            /// maxResults.</summary>
            /// [minimum: 1]
            /// [maximum: 200]
            [Google.Apis.Util.RequestParameterAttribute("maxResults", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<int> MaxResults { get; set; }

            /// <summary>The token returned by the previous request.</summary>
            [Google.Apis.Util.RequestParameterAttribute("pageToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string PageToken { get; set; }


            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "list"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "GET"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "achievements"; }
            }

            /// <summary>Initializes List parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "language", new Google.Apis.Discovery.Parameter
                    {
                        Name = "language",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "maxResults", new Google.Apis.Discovery.Parameter
                    {
                        Name = "maxResults",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "pageToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "pageToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
            }

        }
    }

    /// <summary>The "achievements" collection of methods.</summary>
    public class AchievementsResource
    {
        private const string Resource = "achievements";

        /// <summary>The service which this resource belongs to.</summary>
        private readonly Google.Apis.Services.IClientService service;

        /// <summary>Constructs a new resource.</summary>
        public AchievementsResource(Google.Apis.Services.IClientService service)
        {
            this.service = service;

        }


        /// <summary>Increments the steps of the achievement with the given ID for the currently authenticated
        /// player.</summary>
        /// <param name="achievementId">The ID of the achievement used by this method.</param>
        /// <param
        /// name="stepsToIncrement">The number of steps to increment.</param>
        public virtual IncrementRequest Increment(string achievementId, int stepsToIncrement)
        {
            return new IncrementRequest(service, achievementId, stepsToIncrement);
        }

        /// <summary>Increments the steps of the achievement with the given ID for the currently authenticated
        /// player.</summary>
        public class IncrementRequest : GamesBaseServiceRequest<Google.Apis.Games.v1.Data.AchievementIncrementResponse>
        {
            /// <summary>Constructs a new Increment request.</summary>
            public IncrementRequest(Google.Apis.Services.IClientService service, string achievementId, int stepsToIncrement)
                : base(service)
            {
                AchievementId = achievementId;
                StepsToIncrement = stepsToIncrement;
                InitParameters();
            }


            /// <summary>The ID of the achievement used by this method.</summary>
            [Google.Apis.Util.RequestParameterAttribute("achievementId", Google.Apis.Util.RequestParameterType.Path)]
            public virtual string AchievementId { get; private set; }

            /// <summary>The number of steps to increment.</summary>
            /// [minimum: 1]
            [Google.Apis.Util.RequestParameterAttribute("stepsToIncrement", Google.Apis.Util.RequestParameterType.Query)]
            public virtual int StepsToIncrement { get; private set; }

            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }

            /// <summary>A randomly generated numeric ID for each request specified by the caller. This number is used
            /// at the server to ensure that the request is handled correctly across retries.</summary>
            [Google.Apis.Util.RequestParameterAttribute("requestId", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> RequestId { get; set; }


            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "increment"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "POST"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "achievements/{achievementId}/increment"; }
            }

            /// <summary>Initializes Increment parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "achievementId", new Google.Apis.Discovery.Parameter
                    {
                        Name = "achievementId",
                        IsRequired = true,
                        ParameterType = "path",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "stepsToIncrement", new Google.Apis.Discovery.Parameter
                    {
                        Name = "stepsToIncrement",
                        IsRequired = true,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "requestId", new Google.Apis.Discovery.Parameter
                    {
                        Name = "requestId",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
            }

        }

        /// <summary>Lists the progress for all your application's achievements for the currently authenticated
        /// player.</summary>
        /// <param name="playerId">A player ID. A value of me may be used in place of the authenticated player's
        /// ID.</param>
        public virtual ListRequest List(string playerId)
        {
            return new ListRequest(service, playerId);
        }

        /// <summary>Lists the progress for all your application's achievements for the currently authenticated
        /// player.</summary>
        public class ListRequest : GamesBaseServiceRequest<Google.Apis.Games.v1.Data.PlayerAchievementListResponse>
        {
            /// <summary>Constructs a new List request.</summary>
            public ListRequest(Google.Apis.Services.IClientService service, string playerId)
                : base(service)
            {
                PlayerId = playerId;
                InitParameters();
            }


            /// <summary>A player ID. A value of me may be used in place of the authenticated player's ID.</summary>
            [Google.Apis.Util.RequestParameterAttribute("playerId", Google.Apis.Util.RequestParameterType.Path)]
            public virtual string PlayerId { get; private set; }

            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }

            /// <summary>The preferred language to use for strings returned by this method.</summary>
            [Google.Apis.Util.RequestParameterAttribute("language", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string Language { get; set; }

            /// <summary>The maximum number of achievement resources to return in the response, used for paging. For any
            /// response, the actual number of achievement resources returned may be less than the specified
            /// maxResults.</summary>
            /// [minimum: 1]
            /// [maximum: 200]
            [Google.Apis.Util.RequestParameterAttribute("maxResults", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<int> MaxResults { get; set; }

            /// <summary>The token returned by the previous request.</summary>
            [Google.Apis.Util.RequestParameterAttribute("pageToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string PageToken { get; set; }

            /// <summary>Tells the server to return only achievements with the specified state. If this parameter isn't
            /// specified, all achievements are returned.</summary>
            [Google.Apis.Util.RequestParameterAttribute("state", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<StateEnum> State { get; set; }

            /// <summary>Tells the server to return only achievements with the specified state. If this parameter isn't
            /// specified, all achievements are returned.</summary>
            public enum StateEnum
            {
                /// <summary>List all achievements. This is the default.</summary>
                [Google.Apis.Util.StringValueAttribute("ALL")]
                ALL,
                /// <summary>List only hidden achievements.</summary>
                [Google.Apis.Util.StringValueAttribute("HIDDEN")]
                HIDDEN,
                /// <summary>List only revealed achievements.</summary>
                [Google.Apis.Util.StringValueAttribute("REVEALED")]
                REVEALED,
                /// <summary>List only unlocked achievements.</summary>
                [Google.Apis.Util.StringValueAttribute("UNLOCKED")]
                UNLOCKED,
            }


            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "list"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "GET"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "players/{playerId}/achievements"; }
            }

            /// <summary>Initializes List parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "playerId", new Google.Apis.Discovery.Parameter
                    {
                        Name = "playerId",
                        IsRequired = true,
                        ParameterType = "path",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "language", new Google.Apis.Discovery.Parameter
                    {
                        Name = "language",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "maxResults", new Google.Apis.Discovery.Parameter
                    {
                        Name = "maxResults",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "pageToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "pageToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "state", new Google.Apis.Discovery.Parameter
                    {
                        Name = "state",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
            }

        }

        /// <summary>Sets the state of the achievement with the given ID to REVEALED for the currently authenticated
        /// player.</summary>
        /// <param name="achievementId">The ID of the achievement used by this method.</param>
        public virtual RevealRequest Reveal(string achievementId)
        {
            return new RevealRequest(service, achievementId);
        }

        /// <summary>Sets the state of the achievement with the given ID to REVEALED for the currently authenticated
        /// player.</summary>
        public class RevealRequest : GamesBaseServiceRequest<Google.Apis.Games.v1.Data.AchievementRevealResponse>
        {
            /// <summary>Constructs a new Reveal request.</summary>
            public RevealRequest(Google.Apis.Services.IClientService service, string achievementId)
                : base(service)
            {
                AchievementId = achievementId;
                InitParameters();
            }


            /// <summary>The ID of the achievement used by this method.</summary>
            [Google.Apis.Util.RequestParameterAttribute("achievementId", Google.Apis.Util.RequestParameterType.Path)]
            public virtual string AchievementId { get; private set; }

            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }


            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "reveal"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "POST"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "achievements/{achievementId}/reveal"; }
            }

            /// <summary>Initializes Reveal parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "achievementId", new Google.Apis.Discovery.Parameter
                    {
                        Name = "achievementId",
                        IsRequired = true,
                        ParameterType = "path",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
            }

        }

        /// <summary>Sets the steps for the currently authenticated player towards unlocking an achievement. If the
        /// steps parameter is less than the current number of steps that the player already gained for the achievement,
        /// the achievement is not modified.</summary>
        /// <param name="achievementId">The ID of the achievement used by this method.</param>
        /// <param name="steps">The
        /// minimum value to set the steps to.</param>
        public virtual SetStepsAtLeastRequest SetStepsAtLeast(string achievementId, int steps)
        {
            return new SetStepsAtLeastRequest(service, achievementId, steps);
        }

        /// <summary>Sets the steps for the currently authenticated player towards unlocking an achievement. If the
        /// steps parameter is less than the current number of steps that the player already gained for the achievement,
        /// the achievement is not modified.</summary>
        public class SetStepsAtLeastRequest : GamesBaseServiceRequest<Google.Apis.Games.v1.Data.AchievementSetStepsAtLeastResponse>
        {
            /// <summary>Constructs a new SetStepsAtLeast request.</summary>
            public SetStepsAtLeastRequest(Google.Apis.Services.IClientService service, string achievementId, int steps)
                : base(service)
            {
                AchievementId = achievementId;
                Steps = steps;
                InitParameters();
            }


            /// <summary>The ID of the achievement used by this method.</summary>
            [Google.Apis.Util.RequestParameterAttribute("achievementId", Google.Apis.Util.RequestParameterType.Path)]
            public virtual string AchievementId { get; private set; }

            /// <summary>The minimum value to set the steps to.</summary>
            /// [minimum: 1]
            [Google.Apis.Util.RequestParameterAttribute("steps", Google.Apis.Util.RequestParameterType.Query)]
            public virtual int Steps { get; private set; }

            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }


            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "setStepsAtLeast"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "POST"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "achievements/{achievementId}/setStepsAtLeast"; }
            }

            /// <summary>Initializes SetStepsAtLeast parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "achievementId", new Google.Apis.Discovery.Parameter
                    {
                        Name = "achievementId",
                        IsRequired = true,
                        ParameterType = "path",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "steps", new Google.Apis.Discovery.Parameter
                    {
                        Name = "steps",
                        IsRequired = true,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
            }

        }

        /// <summary>Unlocks this achievement for the currently authenticated player.</summary>
        /// <param name="achievementId">The ID of the achievement used by this method.</param>
        public virtual UnlockRequest Unlock(string achievementId)
        {
            return new UnlockRequest(service, achievementId);
        }

        /// <summary>Unlocks this achievement for the currently authenticated player.</summary>
        public class UnlockRequest : GamesBaseServiceRequest<Google.Apis.Games.v1.Data.AchievementUnlockResponse>
        {
            /// <summary>Constructs a new Unlock request.</summary>
            public UnlockRequest(Google.Apis.Services.IClientService service, string achievementId)
                : base(service)
            {
                AchievementId = achievementId;
                InitParameters();
            }


            /// <summary>The ID of the achievement used by this method.</summary>
            [Google.Apis.Util.RequestParameterAttribute("achievementId", Google.Apis.Util.RequestParameterType.Path)]
            public virtual string AchievementId { get; private set; }

            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }


            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "unlock"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "POST"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "achievements/{achievementId}/unlock"; }
            }

            /// <summary>Initializes Unlock parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "achievementId", new Google.Apis.Discovery.Parameter
                    {
                        Name = "achievementId",
                        IsRequired = true,
                        ParameterType = "path",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
            }

        }

        /// <summary>Updates multiple achievements for the currently authenticated player.</summary>
        /// <param name="body">The body of the request.</param>
        public virtual UpdateMultipleRequest UpdateMultiple(Google.Apis.Games.v1.Data.AchievementUpdateMultipleRequest body)
        {
            return new UpdateMultipleRequest(service, body);
        }

        /// <summary>Updates multiple achievements for the currently authenticated player.</summary>
        public class UpdateMultipleRequest : GamesBaseServiceRequest<Google.Apis.Games.v1.Data.AchievementUpdateMultipleResponse>
        {
            /// <summary>Constructs a new UpdateMultiple request.</summary>
            public UpdateMultipleRequest(Google.Apis.Services.IClientService service, Google.Apis.Games.v1.Data.AchievementUpdateMultipleRequest body)
                : base(service)
            {
                Body = body;
                InitParameters();
            }


            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }


            /// <summary>Gets or sets the body of this request.</summary>
            Google.Apis.Games.v1.Data.AchievementUpdateMultipleRequest Body { get; set; }

            ///<summary>Returns the body of the request.</summary>
            protected override object GetBody() { return Body; }

            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "updateMultiple"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "POST"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "achievements/updateMultiple"; }
            }

            /// <summary>Initializes UpdateMultiple parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
            }

        }
    }

    /// <summary>The "applications" collection of methods.</summary>
    public class ApplicationsResource
    {
        private const string Resource = "applications";

        /// <summary>The service which this resource belongs to.</summary>
        private readonly Google.Apis.Services.IClientService service;

        /// <summary>Constructs a new resource.</summary>
        public ApplicationsResource(Google.Apis.Services.IClientService service)
        {
            this.service = service;

        }


        /// <summary>Retrieves the metadata of the application with the given ID. If the requested application is not
        /// available for the specified platformType, the returned response will not include any instance
        /// data.</summary>
        /// <param name="applicationId">The application ID from the Google Play developer console.</param>
        public virtual GetRequest Get(string applicationId)
        {
            return new GetRequest(service, applicationId);
        }

        /// <summary>Retrieves the metadata of the application with the given ID. If the requested application is not
        /// available for the specified platformType, the returned response will not include any instance
        /// data.</summary>
        public class GetRequest : GamesBaseServiceRequest<Google.Apis.Games.v1.Data.Application>
        {
            /// <summary>Constructs a new Get request.</summary>
            public GetRequest(Google.Apis.Services.IClientService service, string applicationId)
                : base(service)
            {
                ApplicationId = applicationId;
                InitParameters();
            }


            /// <summary>The application ID from the Google Play developer console.</summary>
            [Google.Apis.Util.RequestParameterAttribute("applicationId", Google.Apis.Util.RequestParameterType.Path)]
            public virtual string ApplicationId { get; private set; }

            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }

            /// <summary>The preferred language to use for strings returned by this method.</summary>
            [Google.Apis.Util.RequestParameterAttribute("language", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string Language { get; set; }

            /// <summary>Restrict application details returned to the specific platform.</summary>
            [Google.Apis.Util.RequestParameterAttribute("platformType", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<PlatformTypeEnum> PlatformType { get; set; }

            /// <summary>Restrict application details returned to the specific platform.</summary>
            public enum PlatformTypeEnum
            {
                /// <summary>Retrieve applications that can be played on Android.</summary>
                [Google.Apis.Util.StringValueAttribute("ANDROID")]
                ANDROID,
                /// <summary>Retrieve applications that can be played on iOS.</summary>
                [Google.Apis.Util.StringValueAttribute("IOS")]
                IOS,
                /// <summary>Retrieve applications that can be played on desktop web.</summary>
                [Google.Apis.Util.StringValueAttribute("WEB_APP")]
                WEBAPP,
            }


            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "get"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "GET"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "applications/{applicationId}"; }
            }

            /// <summary>Initializes Get parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "applicationId", new Google.Apis.Discovery.Parameter
                    {
                        Name = "applicationId",
                        IsRequired = true,
                        ParameterType = "path",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "language", new Google.Apis.Discovery.Parameter
                    {
                        Name = "language",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "platformType", new Google.Apis.Discovery.Parameter
                    {
                        Name = "platformType",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
            }

        }

        /// <summary>Indicate that the the currently authenticated user is playing your application.</summary>
        public virtual PlayedRequest Played()
        {
            return new PlayedRequest(service);
        }

        /// <summary>Indicate that the the currently authenticated user is playing your application.</summary>
        public class PlayedRequest : GamesBaseServiceRequest<string>
        {
            /// <summary>Constructs a new Played request.</summary>
            public PlayedRequest(Google.Apis.Services.IClientService service)
                : base(service)
            {
                InitParameters();
            }


            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }


            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "played"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "POST"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "applications/played"; }
            }

            /// <summary>Initializes Played parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
            }

        }

        /// <summary>Verifies the auth token provided with this request is for the application with the specified ID,
        /// and returns the ID of the player it was granted for.</summary>
        /// <param name="applicationId">The application ID from the Google Play developer console.</param>
        public virtual VerifyRequest Verify(string applicationId)
        {
            return new VerifyRequest(service, applicationId);
        }

        /// <summary>Verifies the auth token provided with this request is for the application with the specified ID,
        /// and returns the ID of the player it was granted for.</summary>
        public class VerifyRequest : GamesBaseServiceRequest<Google.Apis.Games.v1.Data.ApplicationVerifyResponse>
        {
            /// <summary>Constructs a new Verify request.</summary>
            public VerifyRequest(Google.Apis.Services.IClientService service, string applicationId)
                : base(service)
            {
                ApplicationId = applicationId;
                InitParameters();
            }


            /// <summary>The application ID from the Google Play developer console.</summary>
            [Google.Apis.Util.RequestParameterAttribute("applicationId", Google.Apis.Util.RequestParameterType.Path)]
            public virtual string ApplicationId { get; private set; }

            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }


            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "verify"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "GET"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "applications/{applicationId}/verify"; }
            }

            /// <summary>Initializes Verify parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "applicationId", new Google.Apis.Discovery.Parameter
                    {
                        Name = "applicationId",
                        IsRequired = true,
                        ParameterType = "path",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
            }

        }
    }

    /// <summary>The "events" collection of methods.</summary>
    public class EventsResource
    {
        private const string Resource = "events";

        /// <summary>The service which this resource belongs to.</summary>
        private readonly Google.Apis.Services.IClientService service;

        /// <summary>Constructs a new resource.</summary>
        public EventsResource(Google.Apis.Services.IClientService service)
        {
            this.service = service;

        }


        /// <summary>Returns a list showing the current progress on events in this application for the currently
        /// authenticated user.</summary>
        public virtual ListByPlayerRequest ListByPlayer()
        {
            return new ListByPlayerRequest(service);
        }

        /// <summary>Returns a list showing the current progress on events in this application for the currently
        /// authenticated user.</summary>
        public class ListByPlayerRequest : GamesBaseServiceRequest<Google.Apis.Games.v1.Data.PlayerEventListResponse>
        {
            /// <summary>Constructs a new ListByPlayer request.</summary>
            public ListByPlayerRequest(Google.Apis.Services.IClientService service)
                : base(service)
            {
                InitParameters();
            }


            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }

            /// <summary>The preferred language to use for strings returned by this method.</summary>
            [Google.Apis.Util.RequestParameterAttribute("language", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string Language { get; set; }

            /// <summary>The maximum number of events to return in the response, used for paging. For any response, the
            /// actual number of events to return may be less than the specified maxResults.</summary>
            /// [minimum: 1]
            /// [maximum: 100]
            [Google.Apis.Util.RequestParameterAttribute("maxResults", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<int> MaxResults { get; set; }

            /// <summary>The token returned by the previous request.</summary>
            [Google.Apis.Util.RequestParameterAttribute("pageToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string PageToken { get; set; }


            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "listByPlayer"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "GET"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "events"; }
            }

            /// <summary>Initializes ListByPlayer parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "language", new Google.Apis.Discovery.Parameter
                    {
                        Name = "language",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "maxResults", new Google.Apis.Discovery.Parameter
                    {
                        Name = "maxResults",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "pageToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "pageToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
            }

        }

        /// <summary>Returns a list of the event definitions in this application.</summary>
        public virtual ListDefinitionsRequest ListDefinitions()
        {
            return new ListDefinitionsRequest(service);
        }

        /// <summary>Returns a list of the event definitions in this application.</summary>
        public class ListDefinitionsRequest : GamesBaseServiceRequest<Google.Apis.Games.v1.Data.EventDefinitionListResponse>
        {
            /// <summary>Constructs a new ListDefinitions request.</summary>
            public ListDefinitionsRequest(Google.Apis.Services.IClientService service)
                : base(service)
            {
                InitParameters();
            }


            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }

            /// <summary>The preferred language to use for strings returned by this method.</summary>
            [Google.Apis.Util.RequestParameterAttribute("language", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string Language { get; set; }

            /// <summary>The maximum number of event definitions to return in the response, used for paging. For any
            /// response, the actual number of event definitions to return may be less than the specified
            /// maxResults.</summary>
            /// [minimum: 1]
            /// [maximum: 100]
            [Google.Apis.Util.RequestParameterAttribute("maxResults", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<int> MaxResults { get; set; }

            /// <summary>The token returned by the previous request.</summary>
            [Google.Apis.Util.RequestParameterAttribute("pageToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string PageToken { get; set; }


            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "listDefinitions"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "GET"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "eventDefinitions"; }
            }

            /// <summary>Initializes ListDefinitions parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "language", new Google.Apis.Discovery.Parameter
                    {
                        Name = "language",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "maxResults", new Google.Apis.Discovery.Parameter
                    {
                        Name = "maxResults",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "pageToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "pageToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
            }

        }

        /// <summary>Records a batch of changes to the number of times events have occurred for the currently
        /// authenticated user of this application.</summary>
        /// <param name="body">The body of the request.</param>
        public virtual RecordRequest Record(Google.Apis.Games.v1.Data.EventRecordRequest body)
        {
            return new RecordRequest(service, body);
        }

        /// <summary>Records a batch of changes to the number of times events have occurred for the currently
        /// authenticated user of this application.</summary>
        public class RecordRequest : GamesBaseServiceRequest<Google.Apis.Games.v1.Data.EventUpdateResponse>
        {
            /// <summary>Constructs a new Record request.</summary>
            public RecordRequest(Google.Apis.Services.IClientService service, Google.Apis.Games.v1.Data.EventRecordRequest body)
                : base(service)
            {
                Body = body;
                InitParameters();
            }


            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }

            /// <summary>The preferred language to use for strings returned by this method.</summary>
            [Google.Apis.Util.RequestParameterAttribute("language", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string Language { get; set; }


            /// <summary>Gets or sets the body of this request.</summary>
            Google.Apis.Games.v1.Data.EventRecordRequest Body { get; set; }

            ///<summary>Returns the body of the request.</summary>
            protected override object GetBody() { return Body; }

            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "record"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "POST"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "events"; }
            }

            /// <summary>Initializes Record parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "language", new Google.Apis.Discovery.Parameter
                    {
                        Name = "language",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
            }

        }
    }

    /// <summary>The "leaderboards" collection of methods.</summary>
    public class LeaderboardsResource
    {
        private const string Resource = "leaderboards";

        /// <summary>The service which this resource belongs to.</summary>
        private readonly Google.Apis.Services.IClientService service;

        /// <summary>Constructs a new resource.</summary>
        public LeaderboardsResource(Google.Apis.Services.IClientService service)
        {
            this.service = service;

        }


        /// <summary>Retrieves the metadata of the leaderboard with the given ID.</summary>
        /// <param name="leaderboardId">The ID of the leaderboard.</param>
        public virtual GetRequest Get(string leaderboardId)
        {
            return new GetRequest(service, leaderboardId);
        }

        /// <summary>Retrieves the metadata of the leaderboard with the given ID.</summary>
        public class GetRequest : GamesBaseServiceRequest<Google.Apis.Games.v1.Data.Leaderboard>
        {
            /// <summary>Constructs a new Get request.</summary>
            public GetRequest(Google.Apis.Services.IClientService service, string leaderboardId)
                : base(service)
            {
                LeaderboardId = leaderboardId;
                InitParameters();
            }


            /// <summary>The ID of the leaderboard.</summary>
            [Google.Apis.Util.RequestParameterAttribute("leaderboardId", Google.Apis.Util.RequestParameterType.Path)]
            public virtual string LeaderboardId { get; private set; }

            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }

            /// <summary>The preferred language to use for strings returned by this method.</summary>
            [Google.Apis.Util.RequestParameterAttribute("language", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string Language { get; set; }


            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "get"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "GET"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "leaderboards/{leaderboardId}"; }
            }

            /// <summary>Initializes Get parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "leaderboardId", new Google.Apis.Discovery.Parameter
                    {
                        Name = "leaderboardId",
                        IsRequired = true,
                        ParameterType = "path",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "language", new Google.Apis.Discovery.Parameter
                    {
                        Name = "language",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
            }

        }

        /// <summary>Lists all the leaderboard metadata for your application.</summary>
        public virtual ListRequest List()
        {
            return new ListRequest(service);
        }

        /// <summary>Lists all the leaderboard metadata for your application.</summary>
        public class ListRequest : GamesBaseServiceRequest<Google.Apis.Games.v1.Data.LeaderboardListResponse>
        {
            /// <summary>Constructs a new List request.</summary>
            public ListRequest(Google.Apis.Services.IClientService service)
                : base(service)
            {
                InitParameters();
            }


            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }

            /// <summary>The preferred language to use for strings returned by this method.</summary>
            [Google.Apis.Util.RequestParameterAttribute("language", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string Language { get; set; }

            /// <summary>The maximum number of leaderboards to return in the response. For any response, the actual
            /// number of leaderboards returned may be less than the specified maxResults.</summary>
            /// [minimum: 1]
            /// [maximum: 200]
            [Google.Apis.Util.RequestParameterAttribute("maxResults", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<int> MaxResults { get; set; }

            /// <summary>The token returned by the previous request.</summary>
            [Google.Apis.Util.RequestParameterAttribute("pageToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string PageToken { get; set; }


            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "list"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "GET"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "leaderboards"; }
            }

            /// <summary>Initializes List parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "language", new Google.Apis.Discovery.Parameter
                    {
                        Name = "language",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "maxResults", new Google.Apis.Discovery.Parameter
                    {
                        Name = "maxResults",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "pageToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "pageToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
            }

        }
    }

    /// <summary>The "metagame" collection of methods.</summary>
    public class MetagameResource
    {
        private const string Resource = "metagame";

        /// <summary>The service which this resource belongs to.</summary>
        private readonly Google.Apis.Services.IClientService service;

        /// <summary>Constructs a new resource.</summary>
        public MetagameResource(Google.Apis.Services.IClientService service)
        {
            this.service = service;

        }


        /// <summary>Return the metagame configuration data for the calling application.</summary>
        public virtual GetMetagameConfigRequest GetMetagameConfig()
        {
            return new GetMetagameConfigRequest(service);
        }

        /// <summary>Return the metagame configuration data for the calling application.</summary>
        public class GetMetagameConfigRequest : GamesBaseServiceRequest<Google.Apis.Games.v1.Data.MetagameConfig>
        {
            /// <summary>Constructs a new GetMetagameConfig request.</summary>
            public GetMetagameConfigRequest(Google.Apis.Services.IClientService service)
                : base(service)
            {
                InitParameters();
            }


            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }


            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "getMetagameConfig"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "GET"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "metagameConfig"; }
            }

            /// <summary>Initializes GetMetagameConfig parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
            }

        }

        /// <summary>List play data aggregated per category for the player corresponding to playerId.</summary>
        /// <param name="playerId">A player ID. A value of me may be used in place of the authenticated player's
        /// ID.</param>
        /// <param name="collection">The collection of categories for which data will be
        /// returned.</param>
        public virtual ListCategoriesByPlayerRequest ListCategoriesByPlayer(string playerId, ListCategoriesByPlayerRequest.CollectionEnum collection)
        {
            return new ListCategoriesByPlayerRequest(service, playerId, collection);
        }

        /// <summary>List play data aggregated per category for the player corresponding to playerId.</summary>
        public class ListCategoriesByPlayerRequest : GamesBaseServiceRequest<Google.Apis.Games.v1.Data.CategoryListResponse>
        {
            /// <summary>Constructs a new ListCategoriesByPlayer request.</summary>
            public ListCategoriesByPlayerRequest(Google.Apis.Services.IClientService service, string playerId, ListCategoriesByPlayerRequest.CollectionEnum collection)
                : base(service)
            {
                PlayerId = playerId;
                Collection = collection;
                InitParameters();
            }


            /// <summary>A player ID. A value of me may be used in place of the authenticated player's ID.</summary>
            [Google.Apis.Util.RequestParameterAttribute("playerId", Google.Apis.Util.RequestParameterType.Path)]
            public virtual string PlayerId { get; private set; }

            /// <summary>The collection of categories for which data will be returned.</summary>
            [Google.Apis.Util.RequestParameterAttribute("collection", Google.Apis.Util.RequestParameterType.Path)]
            public virtual CollectionEnum Collection { get; private set; }

            /// <summary>The collection of categories for which data will be returned.</summary>
            public enum CollectionEnum
            {
                /// <summary>Retrieve data for all categories. This is the default.</summary>
                [Google.Apis.Util.StringValueAttribute("all")]
                All,
            }

            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }

            /// <summary>The preferred language to use for strings returned by this method.</summary>
            [Google.Apis.Util.RequestParameterAttribute("language", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string Language { get; set; }

            /// <summary>The maximum number of category resources to return in the response, used for paging. For any
            /// response, the actual number of category resources returned may be less than the specified
            /// maxResults.</summary>
            /// [minimum: 1]
            /// [maximum: 100]
            [Google.Apis.Util.RequestParameterAttribute("maxResults", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<int> MaxResults { get; set; }

            /// <summary>The token returned by the previous request.</summary>
            [Google.Apis.Util.RequestParameterAttribute("pageToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string PageToken { get; set; }


            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "listCategoriesByPlayer"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "GET"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "players/{playerId}/categories/{collection}"; }
            }

            /// <summary>Initializes ListCategoriesByPlayer parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "playerId", new Google.Apis.Discovery.Parameter
                    {
                        Name = "playerId",
                        IsRequired = true,
                        ParameterType = "path",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "collection", new Google.Apis.Discovery.Parameter
                    {
                        Name = "collection",
                        IsRequired = true,
                        ParameterType = "path",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "language", new Google.Apis.Discovery.Parameter
                    {
                        Name = "language",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "maxResults", new Google.Apis.Discovery.Parameter
                    {
                        Name = "maxResults",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "pageToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "pageToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
            }

        }
    }

    /// <summary>The "players" collection of methods.</summary>
    public class PlayersResource
    {
        private const string Resource = "players";

        /// <summary>The service which this resource belongs to.</summary>
        private readonly Google.Apis.Services.IClientService service;

        /// <summary>Constructs a new resource.</summary>
        public PlayersResource(Google.Apis.Services.IClientService service)
        {
            this.service = service;

        }


        /// <summary>Retrieves the Player resource with the given ID. To retrieve the player for the currently
        /// authenticated user, set playerId to me.</summary>
        /// <param name="playerId">A player ID. A value of me may be used in place of the authenticated player's
        /// ID.</param>
        public virtual GetRequest Get(string playerId)
        {
            return new GetRequest(service, playerId);
        }

        /// <summary>Retrieves the Player resource with the given ID. To retrieve the player for the currently
        /// authenticated user, set playerId to me.</summary>
        public class GetRequest : GamesBaseServiceRequest<Google.Apis.Games.v1.Data.Player>
        {
            /// <summary>Constructs a new Get request.</summary>
            public GetRequest(Google.Apis.Services.IClientService service, string playerId)
                : base(service)
            {
                PlayerId = playerId;
                InitParameters();
            }


            /// <summary>A player ID. A value of me may be used in place of the authenticated player's ID.</summary>
            [Google.Apis.Util.RequestParameterAttribute("playerId", Google.Apis.Util.RequestParameterType.Path)]
            public virtual string PlayerId { get; private set; }

            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }

            /// <summary>The preferred language to use for strings returned by this method.</summary>
            [Google.Apis.Util.RequestParameterAttribute("language", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string Language { get; set; }


            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "get"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "GET"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "players/{playerId}"; }
            }

            /// <summary>Initializes Get parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "playerId", new Google.Apis.Discovery.Parameter
                    {
                        Name = "playerId",
                        IsRequired = true,
                        ParameterType = "path",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "language", new Google.Apis.Discovery.Parameter
                    {
                        Name = "language",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
            }

        }

        /// <summary>Get the collection of players for the currently authenticated user.</summary>
        /// <param name="collection">Collection of players being retrieved</param>
        public virtual ListRequest List(ListRequest.CollectionEnum collection)
        {
            return new ListRequest(service, collection);
        }

        /// <summary>Get the collection of players for the currently authenticated user.</summary>
        public class ListRequest : GamesBaseServiceRequest<Google.Apis.Games.v1.Data.PlayerListResponse>
        {
            /// <summary>Constructs a new List request.</summary>
            public ListRequest(Google.Apis.Services.IClientService service, ListRequest.CollectionEnum collection)
                : base(service)
            {
                Collection = collection;
                InitParameters();
            }


            /// <summary>Collection of players being retrieved</summary>
            [Google.Apis.Util.RequestParameterAttribute("collection", Google.Apis.Util.RequestParameterType.Path)]
            public virtual CollectionEnum Collection { get; private set; }

            /// <summary>Collection of players being retrieved</summary>
            public enum CollectionEnum
            {
                /// <summary>Retrieve a list of players that are also playing this game in reverse chronological
                /// order.</summary>
                [Google.Apis.Util.StringValueAttribute("connected")]
                Connected,
                /// <summary>Retrieve a list of players you have played a multiplayer game (realtime or turn-based) with
                /// recently.</summary>
                [Google.Apis.Util.StringValueAttribute("played_with")]
                PlayedWith,
                /// <summary>Retrieve a list of players in the user's social graph that are visible to this
                /// game.</summary>
                [Google.Apis.Util.StringValueAttribute("visible")]
                Visible,
            }

            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }

            /// <summary>The preferred language to use for strings returned by this method.</summary>
            [Google.Apis.Util.RequestParameterAttribute("language", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string Language { get; set; }

            /// <summary>The maximum number of player resources to return in the response, used for paging. For any
            /// response, the actual number of player resources returned may be less than the specified
            /// maxResults.</summary>
            /// [minimum: 1]
            /// [maximum: 50]
            [Google.Apis.Util.RequestParameterAttribute("maxResults", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<int> MaxResults { get; set; }

            /// <summary>The token returned by the previous request.</summary>
            [Google.Apis.Util.RequestParameterAttribute("pageToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string PageToken { get; set; }


            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "list"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "GET"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "players/me/players/{collection}"; }
            }

            /// <summary>Initializes List parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "collection", new Google.Apis.Discovery.Parameter
                    {
                        Name = "collection",
                        IsRequired = true,
                        ParameterType = "path",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "language", new Google.Apis.Discovery.Parameter
                    {
                        Name = "language",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "maxResults", new Google.Apis.Discovery.Parameter
                    {
                        Name = "maxResults",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "pageToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "pageToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
            }

        }
    }

    /// <summary>The "pushtokens" collection of methods.</summary>
    public class PushtokensResource
    {
        private const string Resource = "pushtokens";

        /// <summary>The service which this resource belongs to.</summary>
        private readonly Google.Apis.Services.IClientService service;

        /// <summary>Constructs a new resource.</summary>
        public PushtokensResource(Google.Apis.Services.IClientService service)
        {
            this.service = service;

        }


        /// <summary>Removes a push token for the current user and application. Removing a non-existent push token will
        /// report success.</summary>
        /// <param name="body">The body of the request.</param>
        public virtual RemoveRequest Remove(Google.Apis.Games.v1.Data.PushTokenId body)
        {
            return new RemoveRequest(service, body);
        }

        /// <summary>Removes a push token for the current user and application. Removing a non-existent push token will
        /// report success.</summary>
        public class RemoveRequest : GamesBaseServiceRequest<string>
        {
            /// <summary>Constructs a new Remove request.</summary>
            public RemoveRequest(Google.Apis.Services.IClientService service, Google.Apis.Games.v1.Data.PushTokenId body)
                : base(service)
            {
                Body = body;
                InitParameters();
            }


            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }


            /// <summary>Gets or sets the body of this request.</summary>
            Google.Apis.Games.v1.Data.PushTokenId Body { get; set; }

            ///<summary>Returns the body of the request.</summary>
            protected override object GetBody() { return Body; }

            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "remove"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "POST"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "pushtokens/remove"; }
            }

            /// <summary>Initializes Remove parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
            }

        }

        /// <summary>Registers a push token for the current user and application.</summary>
        /// <param name="body">The body of the request.</param>
        public virtual UpdateRequest Update(Google.Apis.Games.v1.Data.PushToken body)
        {
            return new UpdateRequest(service, body);
        }

        /// <summary>Registers a push token for the current user and application.</summary>
        public class UpdateRequest : GamesBaseServiceRequest<string>
        {
            /// <summary>Constructs a new Update request.</summary>
            public UpdateRequest(Google.Apis.Services.IClientService service, Google.Apis.Games.v1.Data.PushToken body)
                : base(service)
            {
                Body = body;
                InitParameters();
            }


            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }


            /// <summary>Gets or sets the body of this request.</summary>
            Google.Apis.Games.v1.Data.PushToken Body { get; set; }

            ///<summary>Returns the body of the request.</summary>
            protected override object GetBody() { return Body; }

            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "update"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "PUT"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "pushtokens"; }
            }

            /// <summary>Initializes Update parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
            }

        }
    }

    /// <summary>The "questMilestones" collection of methods.</summary>
    public class QuestMilestonesResource
    {
        private const string Resource = "questMilestones";

        /// <summary>The service which this resource belongs to.</summary>
        private readonly Google.Apis.Services.IClientService service;

        /// <summary>Constructs a new resource.</summary>
        public QuestMilestonesResource(Google.Apis.Services.IClientService service)
        {
            this.service = service;

        }


        /// <summary>Report that a reward for the milestone corresponding to milestoneId for the quest corresponding to
        /// questId has been claimed by the currently authorized user.</summary>
        /// <param name="questId">The ID of the quest.</param>
        /// <param name="milestoneId">The ID of the
        /// milestone.</param>
        /// <param name="requestId">A numeric ID to ensure that the request is handled correctly
        /// across retries. Your client application must generate this ID randomly.</param>
        public virtual ClaimRequest Claim(string questId, string milestoneId, long requestId)
        {
            return new ClaimRequest(service, questId, milestoneId, requestId);
        }

        /// <summary>Report that a reward for the milestone corresponding to milestoneId for the quest corresponding to
        /// questId has been claimed by the currently authorized user.</summary>
        public class ClaimRequest : GamesBaseServiceRequest<string>
        {
            /// <summary>Constructs a new Claim request.</summary>
            public ClaimRequest(Google.Apis.Services.IClientService service, string questId, string milestoneId, long requestId)
                : base(service)
            {
                QuestId = questId;
                MilestoneId = milestoneId;
                RequestId = requestId;
                InitParameters();
            }


            /// <summary>The ID of the quest.</summary>
            [Google.Apis.Util.RequestParameterAttribute("questId", Google.Apis.Util.RequestParameterType.Path)]
            public virtual string QuestId { get; private set; }

            /// <summary>The ID of the milestone.</summary>
            [Google.Apis.Util.RequestParameterAttribute("milestoneId", Google.Apis.Util.RequestParameterType.Path)]
            public virtual string MilestoneId { get; private set; }

            /// <summary>A numeric ID to ensure that the request is handled correctly across retries. Your client
            /// application must generate this ID randomly.</summary>
            [Google.Apis.Util.RequestParameterAttribute("requestId", Google.Apis.Util.RequestParameterType.Query)]
            public virtual long RequestId { get; private set; }

            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }


            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "claim"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "PUT"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "quests/{questId}/milestones/{milestoneId}/claim"; }
            }

            /// <summary>Initializes Claim parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "questId", new Google.Apis.Discovery.Parameter
                    {
                        Name = "questId",
                        IsRequired = true,
                        ParameterType = "path",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "milestoneId", new Google.Apis.Discovery.Parameter
                    {
                        Name = "milestoneId",
                        IsRequired = true,
                        ParameterType = "path",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "requestId", new Google.Apis.Discovery.Parameter
                    {
                        Name = "requestId",
                        IsRequired = true,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
            }

        }
    }

    /// <summary>The "quests" collection of methods.</summary>
    public class QuestsResource
    {
        private const string Resource = "quests";

        /// <summary>The service which this resource belongs to.</summary>
        private readonly Google.Apis.Services.IClientService service;

        /// <summary>Constructs a new resource.</summary>
        public QuestsResource(Google.Apis.Services.IClientService service)
        {
            this.service = service;

        }


        /// <summary>Indicates that the currently authorized user will participate in the quest.</summary>
        /// <param name="questId">The ID of the quest.</param>
        public virtual AcceptRequest Accept(string questId)
        {
            return new AcceptRequest(service, questId);
        }

        /// <summary>Indicates that the currently authorized user will participate in the quest.</summary>
        public class AcceptRequest : GamesBaseServiceRequest<Google.Apis.Games.v1.Data.Quest>
        {
            /// <summary>Constructs a new Accept request.</summary>
            public AcceptRequest(Google.Apis.Services.IClientService service, string questId)
                : base(service)
            {
                QuestId = questId;
                InitParameters();
            }


            /// <summary>The ID of the quest.</summary>
            [Google.Apis.Util.RequestParameterAttribute("questId", Google.Apis.Util.RequestParameterType.Path)]
            public virtual string QuestId { get; private set; }

            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }

            /// <summary>The preferred language to use for strings returned by this method.</summary>
            [Google.Apis.Util.RequestParameterAttribute("language", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string Language { get; set; }


            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "accept"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "POST"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "quests/{questId}/accept"; }
            }

            /// <summary>Initializes Accept parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "questId", new Google.Apis.Discovery.Parameter
                    {
                        Name = "questId",
                        IsRequired = true,
                        ParameterType = "path",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "language", new Google.Apis.Discovery.Parameter
                    {
                        Name = "language",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
            }

        }

        /// <summary>Get a list of quests for your application and the currently authenticated player.</summary>
        /// <param name="playerId">A player ID. A value of me may be used in place of the authenticated player's
        /// ID.</param>
        public virtual ListRequest List(string playerId)
        {
            return new ListRequest(service, playerId);
        }

        /// <summary>Get a list of quests for your application and the currently authenticated player.</summary>
        public class ListRequest : GamesBaseServiceRequest<Google.Apis.Games.v1.Data.QuestListResponse>
        {
            /// <summary>Constructs a new List request.</summary>
            public ListRequest(Google.Apis.Services.IClientService service, string playerId)
                : base(service)
            {
                PlayerId = playerId;
                InitParameters();
            }


            /// <summary>A player ID. A value of me may be used in place of the authenticated player's ID.</summary>
            [Google.Apis.Util.RequestParameterAttribute("playerId", Google.Apis.Util.RequestParameterType.Path)]
            public virtual string PlayerId { get; private set; }

            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }

            /// <summary>The preferred language to use for strings returned by this method.</summary>
            [Google.Apis.Util.RequestParameterAttribute("language", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string Language { get; set; }

            /// <summary>The maximum number of quest resources to return in the response, used for paging. For any
            /// response, the actual number of quest resources returned may be less than the specified maxResults.
            /// Acceptable values are 1 to 50, inclusive. (Default: 50).</summary>
            /// [minimum: 1]
            /// [maximum: 50]
            [Google.Apis.Util.RequestParameterAttribute("maxResults", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<int> MaxResults { get; set; }

            /// <summary>The token returned by the previous request.</summary>
            [Google.Apis.Util.RequestParameterAttribute("pageToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string PageToken { get; set; }


            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "list"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "GET"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "players/{playerId}/quests"; }
            }

            /// <summary>Initializes List parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "playerId", new Google.Apis.Discovery.Parameter
                    {
                        Name = "playerId",
                        IsRequired = true,
                        ParameterType = "path",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "language", new Google.Apis.Discovery.Parameter
                    {
                        Name = "language",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "maxResults", new Google.Apis.Discovery.Parameter
                    {
                        Name = "maxResults",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "pageToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "pageToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
            }

        }
    }

    /// <summary>The "revisions" collection of methods.</summary>
    public class RevisionsResource
    {
        private const string Resource = "revisions";

        /// <summary>The service which this resource belongs to.</summary>
        private readonly Google.Apis.Services.IClientService service;

        /// <summary>Constructs a new resource.</summary>
        public RevisionsResource(Google.Apis.Services.IClientService service)
        {
            this.service = service;

        }


        /// <summary>Checks whether the games client is out of date.</summary>
        /// <param name="clientRevision">The revision of the client SDK used by your application. Format:
        /// [PLATFORM_TYPE]:[VERSION_NUMBER]. Possible values of PLATFORM_TYPE are:   - "ANDROID" - Client is running the
        /// Android SDK.  - "IOS" - Client is running the iOS SDK.  - "WEB_APP" - Client is running as a Web App.</param>
        public virtual CheckRequest Check(string clientRevision)
        {
            return new CheckRequest(service, clientRevision);
        }

        /// <summary>Checks whether the games client is out of date.</summary>
        public class CheckRequest : GamesBaseServiceRequest<Google.Apis.Games.v1.Data.RevisionCheckResponse>
        {
            /// <summary>Constructs a new Check request.</summary>
            public CheckRequest(Google.Apis.Services.IClientService service, string clientRevision)
                : base(service)
            {
                ClientRevision = clientRevision;
                InitParameters();
            }


            /// <summary>The revision of the client SDK used by your application. Format:
            /// [PLATFORM_TYPE]:[VERSION_NUMBER]. Possible values of PLATFORM_TYPE are:
            ///
            /// - "ANDROID" - Client is running the Android SDK. - "IOS" - Client is running the iOS SDK. - "WEB_APP" -
            /// Client is running as a Web App.</summary>
            [Google.Apis.Util.RequestParameterAttribute("clientRevision", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string ClientRevision { get; private set; }

            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }


            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "check"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "GET"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "revisions/check"; }
            }

            /// <summary>Initializes Check parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "clientRevision", new Google.Apis.Discovery.Parameter
                    {
                        Name = "clientRevision",
                        IsRequired = true,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
            }

        }
    }

    /// <summary>The "rooms" collection of methods.</summary>
    public class RoomsResource
    {
        private const string Resource = "rooms";

        /// <summary>The service which this resource belongs to.</summary>
        private readonly Google.Apis.Services.IClientService service;

        /// <summary>Constructs a new resource.</summary>
        public RoomsResource(Google.Apis.Services.IClientService service)
        {
            this.service = service;

        }


        /// <summary>Create a room. For internal use by the Games SDK only. Calling this method directly is
        /// unsupported.</summary>
        /// <param name="body">The body of the request.</param>
        public virtual CreateRequest Create(Google.Apis.Games.v1.Data.RoomCreateRequest body)
        {
            return new CreateRequest(service, body);
        }

        /// <summary>Create a room. For internal use by the Games SDK only. Calling this method directly is
        /// unsupported.</summary>
        public class CreateRequest : GamesBaseServiceRequest<Google.Apis.Games.v1.Data.Room>
        {
            /// <summary>Constructs a new Create request.</summary>
            public CreateRequest(Google.Apis.Services.IClientService service, Google.Apis.Games.v1.Data.RoomCreateRequest body)
                : base(service)
            {
                Body = body;
                InitParameters();
            }


            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }

            /// <summary>The preferred language to use for strings returned by this method.</summary>
            [Google.Apis.Util.RequestParameterAttribute("language", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string Language { get; set; }


            /// <summary>Gets or sets the body of this request.</summary>
            Google.Apis.Games.v1.Data.RoomCreateRequest Body { get; set; }

            ///<summary>Returns the body of the request.</summary>
            protected override object GetBody() { return Body; }

            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "create"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "POST"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "rooms/create"; }
            }

            /// <summary>Initializes Create parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "language", new Google.Apis.Discovery.Parameter
                    {
                        Name = "language",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
            }

        }

        /// <summary>Decline an invitation to join a room. For internal use by the Games SDK only. Calling this method
        /// directly is unsupported.</summary>
        /// <param name="roomId">The ID of the room.</param>
        public virtual DeclineRequest Decline(string roomId)
        {
            return new DeclineRequest(service, roomId);
        }

        /// <summary>Decline an invitation to join a room. For internal use by the Games SDK only. Calling this method
        /// directly is unsupported.</summary>
        public class DeclineRequest : GamesBaseServiceRequest<Google.Apis.Games.v1.Data.Room>
        {
            /// <summary>Constructs a new Decline request.</summary>
            public DeclineRequest(Google.Apis.Services.IClientService service, string roomId)
                : base(service)
            {
                RoomId = roomId;
                InitParameters();
            }


            /// <summary>The ID of the room.</summary>
            [Google.Apis.Util.RequestParameterAttribute("roomId", Google.Apis.Util.RequestParameterType.Path)]
            public virtual string RoomId { get; private set; }

            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }

            /// <summary>The preferred language to use for strings returned by this method.</summary>
            [Google.Apis.Util.RequestParameterAttribute("language", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string Language { get; set; }


            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "decline"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "POST"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "rooms/{roomId}/decline"; }
            }

            /// <summary>Initializes Decline parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "roomId", new Google.Apis.Discovery.Parameter
                    {
                        Name = "roomId",
                        IsRequired = true,
                        ParameterType = "path",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "language", new Google.Apis.Discovery.Parameter
                    {
                        Name = "language",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
            }

        }

        /// <summary>Dismiss an invitation to join a room. For internal use by the Games SDK only. Calling this method
        /// directly is unsupported.</summary>
        /// <param name="roomId">The ID of the room.</param>
        public virtual DismissRequest Dismiss(string roomId)
        {
            return new DismissRequest(service, roomId);
        }

        /// <summary>Dismiss an invitation to join a room. For internal use by the Games SDK only. Calling this method
        /// directly is unsupported.</summary>
        public class DismissRequest : GamesBaseServiceRequest<string>
        {
            /// <summary>Constructs a new Dismiss request.</summary>
            public DismissRequest(Google.Apis.Services.IClientService service, string roomId)
                : base(service)
            {
                RoomId = roomId;
                InitParameters();
            }


            /// <summary>The ID of the room.</summary>
            [Google.Apis.Util.RequestParameterAttribute("roomId", Google.Apis.Util.RequestParameterType.Path)]
            public virtual string RoomId { get; private set; }

            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }


            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "dismiss"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "POST"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "rooms/{roomId}/dismiss"; }
            }

            /// <summary>Initializes Dismiss parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "roomId", new Google.Apis.Discovery.Parameter
                    {
                        Name = "roomId",
                        IsRequired = true,
                        ParameterType = "path",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
            }

        }

        /// <summary>Get the data for a room.</summary>
        /// <param name="roomId">The ID of the room.</param>
        public virtual GetRequest Get(string roomId)
        {
            return new GetRequest(service, roomId);
        }

        /// <summary>Get the data for a room.</summary>
        public class GetRequest : GamesBaseServiceRequest<Google.Apis.Games.v1.Data.Room>
        {
            /// <summary>Constructs a new Get request.</summary>
            public GetRequest(Google.Apis.Services.IClientService service, string roomId)
                : base(service)
            {
                RoomId = roomId;
                InitParameters();
            }


            /// <summary>The ID of the room.</summary>
            [Google.Apis.Util.RequestParameterAttribute("roomId", Google.Apis.Util.RequestParameterType.Path)]
            public virtual string RoomId { get; private set; }

            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }

            /// <summary>The preferred language to use for strings returned by this method.</summary>
            [Google.Apis.Util.RequestParameterAttribute("language", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string Language { get; set; }


            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "get"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "GET"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "rooms/{roomId}"; }
            }

            /// <summary>Initializes Get parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "roomId", new Google.Apis.Discovery.Parameter
                    {
                        Name = "roomId",
                        IsRequired = true,
                        ParameterType = "path",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "language", new Google.Apis.Discovery.Parameter
                    {
                        Name = "language",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
            }

        }

        /// <summary>Join a room. For internal use by the Games SDK only. Calling this method directly is
        /// unsupported.</summary>
        /// <param name="body">The body of the request.</param>
        /// <param name="roomId">The ID of the room.</param>
        public virtual JoinRequest Join(Google.Apis.Games.v1.Data.RoomJoinRequest body, string roomId)
        {
            return new JoinRequest(service, body, roomId);
        }

        /// <summary>Join a room. For internal use by the Games SDK only. Calling this method directly is
        /// unsupported.</summary>
        public class JoinRequest : GamesBaseServiceRequest<Google.Apis.Games.v1.Data.Room>
        {
            /// <summary>Constructs a new Join request.</summary>
            public JoinRequest(Google.Apis.Services.IClientService service, Google.Apis.Games.v1.Data.RoomJoinRequest body, string roomId)
                : base(service)
            {
                RoomId = roomId;
                Body = body;
                InitParameters();
            }


            /// <summary>The ID of the room.</summary>
            [Google.Apis.Util.RequestParameterAttribute("roomId", Google.Apis.Util.RequestParameterType.Path)]
            public virtual string RoomId { get; private set; }

            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }

            /// <summary>The preferred language to use for strings returned by this method.</summary>
            [Google.Apis.Util.RequestParameterAttribute("language", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string Language { get; set; }


            /// <summary>Gets or sets the body of this request.</summary>
            Google.Apis.Games.v1.Data.RoomJoinRequest Body { get; set; }

            ///<summary>Returns the body of the request.</summary>
            protected override object GetBody() { return Body; }

            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "join"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "POST"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "rooms/{roomId}/join"; }
            }

            /// <summary>Initializes Join parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "roomId", new Google.Apis.Discovery.Parameter
                    {
                        Name = "roomId",
                        IsRequired = true,
                        ParameterType = "path",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "language", new Google.Apis.Discovery.Parameter
                    {
                        Name = "language",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
            }

        }

        /// <summary>Leave a room. For internal use by the Games SDK only. Calling this method directly is
        /// unsupported.</summary>
        /// <param name="body">The body of the request.</param>
        /// <param name="roomId">The ID of the room.</param>
        public virtual LeaveRequest Leave(Google.Apis.Games.v1.Data.RoomLeaveRequest body, string roomId)
        {
            return new LeaveRequest(service, body, roomId);
        }

        /// <summary>Leave a room. For internal use by the Games SDK only. Calling this method directly is
        /// unsupported.</summary>
        public class LeaveRequest : GamesBaseServiceRequest<Google.Apis.Games.v1.Data.Room>
        {
            /// <summary>Constructs a new Leave request.</summary>
            public LeaveRequest(Google.Apis.Services.IClientService service, Google.Apis.Games.v1.Data.RoomLeaveRequest body, string roomId)
                : base(service)
            {
                RoomId = roomId;
                Body = body;
                InitParameters();
            }


            /// <summary>The ID of the room.</summary>
            [Google.Apis.Util.RequestParameterAttribute("roomId", Google.Apis.Util.RequestParameterType.Path)]
            public virtual string RoomId { get; private set; }

            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }

            /// <summary>The preferred language to use for strings returned by this method.</summary>
            [Google.Apis.Util.RequestParameterAttribute("language", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string Language { get; set; }


            /// <summary>Gets or sets the body of this request.</summary>
            Google.Apis.Games.v1.Data.RoomLeaveRequest Body { get; set; }

            ///<summary>Returns the body of the request.</summary>
            protected override object GetBody() { return Body; }

            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "leave"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "POST"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "rooms/{roomId}/leave"; }
            }

            /// <summary>Initializes Leave parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "roomId", new Google.Apis.Discovery.Parameter
                    {
                        Name = "roomId",
                        IsRequired = true,
                        ParameterType = "path",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "language", new Google.Apis.Discovery.Parameter
                    {
                        Name = "language",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
            }

        }

        /// <summary>Returns invitations to join rooms.</summary>
        public virtual ListRequest List()
        {
            return new ListRequest(service);
        }

        /// <summary>Returns invitations to join rooms.</summary>
        public class ListRequest : GamesBaseServiceRequest<Google.Apis.Games.v1.Data.RoomList>
        {
            /// <summary>Constructs a new List request.</summary>
            public ListRequest(Google.Apis.Services.IClientService service)
                : base(service)
            {
                InitParameters();
            }


            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }

            /// <summary>The preferred language to use for strings returned by this method.</summary>
            [Google.Apis.Util.RequestParameterAttribute("language", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string Language { get; set; }

            /// <summary>The maximum number of rooms to return in the response, used for paging. For any response, the
            /// actual number of rooms to return may be less than the specified maxResults.</summary>
            /// [minimum: 1]
            /// [maximum: 500]
            [Google.Apis.Util.RequestParameterAttribute("maxResults", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<int> MaxResults { get; set; }

            /// <summary>The token returned by the previous request.</summary>
            [Google.Apis.Util.RequestParameterAttribute("pageToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string PageToken { get; set; }


            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "list"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "GET"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "rooms"; }
            }

            /// <summary>Initializes List parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "language", new Google.Apis.Discovery.Parameter
                    {
                        Name = "language",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "maxResults", new Google.Apis.Discovery.Parameter
                    {
                        Name = "maxResults",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "pageToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "pageToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
            }

        }

        /// <summary>Updates sent by a client reporting the status of peers in a room. For internal use by the Games SDK
        /// only. Calling this method directly is unsupported.</summary>
        /// <param name="body">The body of the request.</param>
        /// <param name="roomId">The ID of the room.</param>
        public virtual ReportStatusRequest ReportStatus(Google.Apis.Games.v1.Data.RoomP2PStatuses body, string roomId)
        {
            return new ReportStatusRequest(service, body, roomId);
        }

        /// <summary>Updates sent by a client reporting the status of peers in a room. For internal use by the Games SDK
        /// only. Calling this method directly is unsupported.</summary>
        public class ReportStatusRequest : GamesBaseServiceRequest<Google.Apis.Games.v1.Data.RoomStatus>
        {
            /// <summary>Constructs a new ReportStatus request.</summary>
            public ReportStatusRequest(Google.Apis.Services.IClientService service, Google.Apis.Games.v1.Data.RoomP2PStatuses body, string roomId)
                : base(service)
            {
                RoomId = roomId;
                Body = body;
                InitParameters();
            }


            /// <summary>The ID of the room.</summary>
            [Google.Apis.Util.RequestParameterAttribute("roomId", Google.Apis.Util.RequestParameterType.Path)]
            public virtual string RoomId { get; private set; }

            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }

            /// <summary>The preferred language to use for strings returned by this method.</summary>
            [Google.Apis.Util.RequestParameterAttribute("language", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string Language { get; set; }


            /// <summary>Gets or sets the body of this request.</summary>
            Google.Apis.Games.v1.Data.RoomP2PStatuses Body { get; set; }

            ///<summary>Returns the body of the request.</summary>
            protected override object GetBody() { return Body; }

            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "reportStatus"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "POST"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "rooms/{roomId}/reportstatus"; }
            }

            /// <summary>Initializes ReportStatus parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "roomId", new Google.Apis.Discovery.Parameter
                    {
                        Name = "roomId",
                        IsRequired = true,
                        ParameterType = "path",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "language", new Google.Apis.Discovery.Parameter
                    {
                        Name = "language",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
            }

        }
    }

    /// <summary>The "scores" collection of methods.</summary>
    public class ScoresResource
    {
        private const string Resource = "scores";

        /// <summary>The service which this resource belongs to.</summary>
        private readonly Google.Apis.Services.IClientService service;

        /// <summary>Constructs a new resource.</summary>
        public ScoresResource(Google.Apis.Services.IClientService service)
        {
            this.service = service;

        }


        /// <summary>Get high scores, and optionally ranks, in leaderboards for the currently authenticated player. For
        /// a specific time span, leaderboardId can be set to ALL to retrieve data for all leaderboards in a given time
        /// span. NOTE: You cannot ask for 'ALL' leaderboards and 'ALL' timeSpans in the same request; only one
        /// parameter may be set to 'ALL'.</summary>
        /// <param name="playerId">A player ID. A value of me may be used in place of the authenticated player's
        /// ID.</param>
        /// <param name="leaderboardId">The ID of the leaderboard. Can be set to 'ALL' to retrieve data for
        /// all leaderboards for this application.</param>
        /// <param name="timeSpan">The time span for the scores and ranks
        /// you're requesting.</param>
        public virtual GetRequest Get(string playerId, string leaderboardId, GetRequest.TimeSpanEnum timeSpan)
        {
            return new GetRequest(service, playerId, leaderboardId, timeSpan);
        }

        /// <summary>Get high scores, and optionally ranks, in leaderboards for the currently authenticated player. For
        /// a specific time span, leaderboardId can be set to ALL to retrieve data for all leaderboards in a given time
        /// span. NOTE: You cannot ask for 'ALL' leaderboards and 'ALL' timeSpans in the same request; only one
        /// parameter may be set to 'ALL'.</summary>
        public class GetRequest : GamesBaseServiceRequest<Google.Apis.Games.v1.Data.PlayerLeaderboardScoreListResponse>
        {
            /// <summary>Constructs a new Get request.</summary>
            public GetRequest(Google.Apis.Services.IClientService service, string playerId, string leaderboardId, GetRequest.TimeSpanEnum timeSpan)
                : base(service)
            {
                PlayerId = playerId;
                LeaderboardId = leaderboardId;
                TimeSpan = timeSpan;
                InitParameters();
            }


            /// <summary>A player ID. A value of me may be used in place of the authenticated player's ID.</summary>
            [Google.Apis.Util.RequestParameterAttribute("playerId", Google.Apis.Util.RequestParameterType.Path)]
            public virtual string PlayerId { get; private set; }

            /// <summary>The ID of the leaderboard. Can be set to 'ALL' to retrieve data for all leaderboards for this
            /// application.</summary>
            [Google.Apis.Util.RequestParameterAttribute("leaderboardId", Google.Apis.Util.RequestParameterType.Path)]
            public virtual string LeaderboardId { get; private set; }

            /// <summary>The time span for the scores and ranks you're requesting.</summary>
            [Google.Apis.Util.RequestParameterAttribute("timeSpan", Google.Apis.Util.RequestParameterType.Path)]
            public virtual TimeSpanEnum TimeSpan { get; private set; }

            /// <summary>The time span for the scores and ranks you're requesting.</summary>
            public enum TimeSpanEnum
            {
                /// <summary>Get the high scores for all time spans. If this is used, maxResults values will be
                /// ignored.</summary>
                [Google.Apis.Util.StringValueAttribute("ALL")]
                ALL,
                /// <summary>Get the all time high score.</summary>
                [Google.Apis.Util.StringValueAttribute("ALL_TIME")]
                ALLTIME,
                /// <summary>List the top scores for the current day.</summary>
                [Google.Apis.Util.StringValueAttribute("DAILY")]
                DAILY,
                /// <summary>List the top scores for the current week.</summary>
                [Google.Apis.Util.StringValueAttribute("WEEKLY")]
                WEEKLY,
            }

            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }

            /// <summary>The types of ranks to return. If the parameter is omitted, no ranks will be returned.</summary>
            [Google.Apis.Util.RequestParameterAttribute("includeRankType", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<IncludeRankTypeEnum> IncludeRankType { get; set; }

            /// <summary>The types of ranks to return. If the parameter is omitted, no ranks will be returned.</summary>
            public enum IncludeRankTypeEnum
            {
                /// <summary>Retrieve public and social ranks.</summary>
                [Google.Apis.Util.StringValueAttribute("ALL")]
                ALL,
                /// <summary>Retrieve public ranks, if the player is sharing their gameplay activity publicly.</summary>
                [Google.Apis.Util.StringValueAttribute("PUBLIC")]
                PUBLIC__,
                /// <summary>Retrieve the social rank.</summary>
                [Google.Apis.Util.StringValueAttribute("SOCIAL")]
                SOCIAL,
            }

            /// <summary>The preferred language to use for strings returned by this method.</summary>
            [Google.Apis.Util.RequestParameterAttribute("language", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string Language { get; set; }

            /// <summary>The maximum number of leaderboard scores to return in the response. For any response, the
            /// actual number of leaderboard scores returned may be less than the specified maxResults.</summary>
            /// [minimum: 1]
            /// [maximum: 30]
            [Google.Apis.Util.RequestParameterAttribute("maxResults", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<int> MaxResults { get; set; }

            /// <summary>The token returned by the previous request.</summary>
            [Google.Apis.Util.RequestParameterAttribute("pageToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string PageToken { get; set; }


            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "get"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "GET"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "players/{playerId}/leaderboards/{leaderboardId}/scores/{timeSpan}"; }
            }

            /// <summary>Initializes Get parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "playerId", new Google.Apis.Discovery.Parameter
                    {
                        Name = "playerId",
                        IsRequired = true,
                        ParameterType = "path",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "leaderboardId", new Google.Apis.Discovery.Parameter
                    {
                        Name = "leaderboardId",
                        IsRequired = true,
                        ParameterType = "path",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "timeSpan", new Google.Apis.Discovery.Parameter
                    {
                        Name = "timeSpan",
                        IsRequired = true,
                        ParameterType = "path",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "includeRankType", new Google.Apis.Discovery.Parameter
                    {
                        Name = "includeRankType",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "language", new Google.Apis.Discovery.Parameter
                    {
                        Name = "language",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "maxResults", new Google.Apis.Discovery.Parameter
                    {
                        Name = "maxResults",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "pageToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "pageToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
            }

        }

        /// <summary>Lists the scores in a leaderboard, starting from the top.</summary>
        /// <param name="leaderboardId">The ID of the leaderboard.</param>
        /// <param name="collection">The collection of
        /// scores you're requesting.</param>
        /// <param name="timeSpan">The time span for the scores and ranks you're
        /// requesting.</param>
        public virtual ListRequest List(string leaderboardId, ListRequest.CollectionEnum collection, ListRequest.TimeSpanEnum timeSpan)
        {
            return new ListRequest(service, leaderboardId, collection, timeSpan);
        }

        /// <summary>Lists the scores in a leaderboard, starting from the top.</summary>
        public class ListRequest : GamesBaseServiceRequest<Google.Apis.Games.v1.Data.LeaderboardScores>
        {
            /// <summary>Constructs a new List request.</summary>
            public ListRequest(Google.Apis.Services.IClientService service, string leaderboardId, ListRequest.CollectionEnum collection, ListRequest.TimeSpanEnum timeSpan)
                : base(service)
            {
                LeaderboardId = leaderboardId;
                Collection = collection;
                TimeSpan = timeSpan;
                InitParameters();
            }


            /// <summary>The ID of the leaderboard.</summary>
            [Google.Apis.Util.RequestParameterAttribute("leaderboardId", Google.Apis.Util.RequestParameterType.Path)]
            public virtual string LeaderboardId { get; private set; }

            /// <summary>The collection of scores you're requesting.</summary>
            [Google.Apis.Util.RequestParameterAttribute("collection", Google.Apis.Util.RequestParameterType.Path)]
            public virtual CollectionEnum Collection { get; private set; }

            /// <summary>The collection of scores you're requesting.</summary>
            public enum CollectionEnum
            {
                /// <summary>List all scores in the public leaderboard.</summary>
                [Google.Apis.Util.StringValueAttribute("PUBLIC")]
                PUBLIC__,
                /// <summary>List only social scores.</summary>
                [Google.Apis.Util.StringValueAttribute("SOCIAL")]
                SOCIAL,
                /// <summary>List only social scores, not respecting the fACL.</summary>
                [Google.Apis.Util.StringValueAttribute("SOCIAL_1P")]
                SOCIAL1P,
            }

            /// <summary>The time span for the scores and ranks you're requesting.</summary>
            [Google.Apis.Util.RequestParameterAttribute("timeSpan", Google.Apis.Util.RequestParameterType.Query)]
            public virtual TimeSpanEnum TimeSpan { get; private set; }

            /// <summary>The time span for the scores and ranks you're requesting.</summary>
            public enum TimeSpanEnum
            {
                /// <summary>List the all-time top scores.</summary>
                [Google.Apis.Util.StringValueAttribute("ALL_TIME")]
                ALLTIME,
                /// <summary>List the top scores for the current day.</summary>
                [Google.Apis.Util.StringValueAttribute("DAILY")]
                DAILY,
                /// <summary>List the top scores for the current week.</summary>
                [Google.Apis.Util.StringValueAttribute("WEEKLY")]
                WEEKLY,
            }

            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }

            /// <summary>The preferred language to use for strings returned by this method.</summary>
            [Google.Apis.Util.RequestParameterAttribute("language", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string Language { get; set; }

            /// <summary>The maximum number of leaderboard scores to return in the response. For any response, the
            /// actual number of leaderboard scores returned may be less than the specified maxResults.</summary>
            /// [minimum: 1]
            /// [maximum: 30]
            [Google.Apis.Util.RequestParameterAttribute("maxResults", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<int> MaxResults { get; set; }

            /// <summary>The token returned by the previous request.</summary>
            [Google.Apis.Util.RequestParameterAttribute("pageToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string PageToken { get; set; }


            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "list"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "GET"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "leaderboards/{leaderboardId}/scores/{collection}"; }
            }

            /// <summary>Initializes List parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "leaderboardId", new Google.Apis.Discovery.Parameter
                    {
                        Name = "leaderboardId",
                        IsRequired = true,
                        ParameterType = "path",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "collection", new Google.Apis.Discovery.Parameter
                    {
                        Name = "collection",
                        IsRequired = true,
                        ParameterType = "path",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "timeSpan", new Google.Apis.Discovery.Parameter
                    {
                        Name = "timeSpan",
                        IsRequired = true,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "language", new Google.Apis.Discovery.Parameter
                    {
                        Name = "language",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "maxResults", new Google.Apis.Discovery.Parameter
                    {
                        Name = "maxResults",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "pageToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "pageToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
            }

        }

        /// <summary>Lists the scores in a leaderboard around (and including) a player's score.</summary>
        /// <param name="leaderboardId">The ID of the leaderboard.</param>
        /// <param name="collection">The collection of
        /// scores you're requesting.</param>
        /// <param name="timeSpan">The time span for the scores and ranks you're
        /// requesting.</param>
        public virtual ListWindowRequest ListWindow(string leaderboardId, ListWindowRequest.CollectionEnum collection, ListWindowRequest.TimeSpanEnum timeSpan)
        {
            return new ListWindowRequest(service, leaderboardId, collection, timeSpan);
        }

        /// <summary>Lists the scores in a leaderboard around (and including) a player's score.</summary>
        public class ListWindowRequest : GamesBaseServiceRequest<Google.Apis.Games.v1.Data.LeaderboardScores>
        {
            /// <summary>Constructs a new ListWindow request.</summary>
            public ListWindowRequest(Google.Apis.Services.IClientService service, string leaderboardId, ListWindowRequest.CollectionEnum collection, ListWindowRequest.TimeSpanEnum timeSpan)
                : base(service)
            {
                LeaderboardId = leaderboardId;
                Collection = collection;
                TimeSpan = timeSpan;
                InitParameters();
            }


            /// <summary>The ID of the leaderboard.</summary>
            [Google.Apis.Util.RequestParameterAttribute("leaderboardId", Google.Apis.Util.RequestParameterType.Path)]
            public virtual string LeaderboardId { get; private set; }

            /// <summary>The collection of scores you're requesting.</summary>
            [Google.Apis.Util.RequestParameterAttribute("collection", Google.Apis.Util.RequestParameterType.Path)]
            public virtual CollectionEnum Collection { get; private set; }

            /// <summary>The collection of scores you're requesting.</summary>
            public enum CollectionEnum
            {
                /// <summary>List all scores in the public leaderboard.</summary>
                [Google.Apis.Util.StringValueAttribute("PUBLIC")]
                PUBLIC__,
                /// <summary>List only social scores.</summary>
                [Google.Apis.Util.StringValueAttribute("SOCIAL")]
                SOCIAL,
                /// <summary>List only social scores, not respecting the fACL.</summary>
                [Google.Apis.Util.StringValueAttribute("SOCIAL_1P")]
                SOCIAL1P,
            }

            /// <summary>The time span for the scores and ranks you're requesting.</summary>
            [Google.Apis.Util.RequestParameterAttribute("timeSpan", Google.Apis.Util.RequestParameterType.Query)]
            public virtual TimeSpanEnum TimeSpan { get; private set; }

            /// <summary>The time span for the scores and ranks you're requesting.</summary>
            public enum TimeSpanEnum
            {
                /// <summary>List the all-time top scores.</summary>
                [Google.Apis.Util.StringValueAttribute("ALL_TIME")]
                ALLTIME,
                /// <summary>List the top scores for the current day.</summary>
                [Google.Apis.Util.StringValueAttribute("DAILY")]
                DAILY,
                /// <summary>List the top scores for the current week.</summary>
                [Google.Apis.Util.StringValueAttribute("WEEKLY")]
                WEEKLY,
            }

            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }

            /// <summary>The preferred language to use for strings returned by this method.</summary>
            [Google.Apis.Util.RequestParameterAttribute("language", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string Language { get; set; }

            /// <summary>The maximum number of leaderboard scores to return in the response. For any response, the
            /// actual number of leaderboard scores returned may be less than the specified maxResults.</summary>
            /// [minimum: 1]
            /// [maximum: 30]
            [Google.Apis.Util.RequestParameterAttribute("maxResults", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<int> MaxResults { get; set; }

            /// <summary>The token returned by the previous request.</summary>
            [Google.Apis.Util.RequestParameterAttribute("pageToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string PageToken { get; set; }

            /// <summary>The preferred number of scores to return above the player's score. More scores may be returned
            /// if the player is at the bottom of the leaderboard; fewer may be returned if the player is at the top.
            /// Must be less than or equal to maxResults.</summary>
            [Google.Apis.Util.RequestParameterAttribute("resultsAbove", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<int> ResultsAbove { get; set; }

            /// <summary>True if the top scores should be returned when the player is not in the leaderboard. Defaults
            /// to true.</summary>
            [Google.Apis.Util.RequestParameterAttribute("returnTopIfAbsent", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<bool> ReturnTopIfAbsent { get; set; }


            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "listWindow"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "GET"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "leaderboards/{leaderboardId}/window/{collection}"; }
            }

            /// <summary>Initializes ListWindow parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "leaderboardId", new Google.Apis.Discovery.Parameter
                    {
                        Name = "leaderboardId",
                        IsRequired = true,
                        ParameterType = "path",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "collection", new Google.Apis.Discovery.Parameter
                    {
                        Name = "collection",
                        IsRequired = true,
                        ParameterType = "path",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "timeSpan", new Google.Apis.Discovery.Parameter
                    {
                        Name = "timeSpan",
                        IsRequired = true,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "language", new Google.Apis.Discovery.Parameter
                    {
                        Name = "language",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "maxResults", new Google.Apis.Discovery.Parameter
                    {
                        Name = "maxResults",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "pageToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "pageToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "resultsAbove", new Google.Apis.Discovery.Parameter
                    {
                        Name = "resultsAbove",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "returnTopIfAbsent", new Google.Apis.Discovery.Parameter
                    {
                        Name = "returnTopIfAbsent",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
            }

        }

        /// <summary>Submits a score to the specified leaderboard.</summary>
        /// <param name="leaderboardId">The ID of the leaderboard.</param>
        /// <param name="score">The score you're
        /// submitting. The submitted score is ignored if it is worse than a previously submitted score, where worse depends on
        /// the leaderboard sort order. The meaning of the score value depends on the leaderboard format type. For fixed-point,
        /// the score represents the raw value. For time, the score represents elapsed time in milliseconds. For currency, the
        /// score represents a value in micro units.</param>
        public virtual SubmitRequest Submit(string leaderboardId, long score)
        {
            return new SubmitRequest(service, leaderboardId, score);
        }

        /// <summary>Submits a score to the specified leaderboard.</summary>
        public class SubmitRequest : GamesBaseServiceRequest<Google.Apis.Games.v1.Data.PlayerScoreResponse>
        {
            /// <summary>Constructs a new Submit request.</summary>
            public SubmitRequest(Google.Apis.Services.IClientService service, string leaderboardId, long score)
                : base(service)
            {
                LeaderboardId = leaderboardId;
                Score = score;
                InitParameters();
            }


            /// <summary>The ID of the leaderboard.</summary>
            [Google.Apis.Util.RequestParameterAttribute("leaderboardId", Google.Apis.Util.RequestParameterType.Path)]
            public virtual string LeaderboardId { get; private set; }

            /// <summary>The score you're submitting. The submitted score is ignored if it is worse than a previously
            /// submitted score, where worse depends on the leaderboard sort order. The meaning of the score value
            /// depends on the leaderboard format type. For fixed-point, the score represents the raw value. For time,
            /// the score represents elapsed time in milliseconds. For currency, the score represents a value in micro
            /// units.</summary>
            [Google.Apis.Util.RequestParameterAttribute("score", Google.Apis.Util.RequestParameterType.Query)]
            public virtual long Score { get; private set; }

            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }

            /// <summary>The preferred language to use for strings returned by this method.</summary>
            [Google.Apis.Util.RequestParameterAttribute("language", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string Language { get; set; }

            /// <summary>Additional information about the score you're submitting. Values must contain no more than 64
            /// URI-safe characters as defined by section 2.3 of RFC 3986.</summary>
            [Google.Apis.Util.RequestParameterAttribute("scoreTag", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string ScoreTag { get; set; }


            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "submit"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "POST"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "leaderboards/{leaderboardId}/scores"; }
            }

            /// <summary>Initializes Submit parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "leaderboardId", new Google.Apis.Discovery.Parameter
                    {
                        Name = "leaderboardId",
                        IsRequired = true,
                        ParameterType = "path",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "score", new Google.Apis.Discovery.Parameter
                    {
                        Name = "score",
                        IsRequired = true,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "language", new Google.Apis.Discovery.Parameter
                    {
                        Name = "language",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "scoreTag", new Google.Apis.Discovery.Parameter
                    {
                        Name = "scoreTag",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = @"[a-zA-Z0-9-._~]{0,64}",
                    });
            }

        }

        /// <summary>Submits multiple scores to leaderboards.</summary>
        /// <param name="body">The body of the request.</param>
        public virtual SubmitMultipleRequest SubmitMultiple(Google.Apis.Games.v1.Data.PlayerScoreSubmissionList body)
        {
            return new SubmitMultipleRequest(service, body);
        }

        /// <summary>Submits multiple scores to leaderboards.</summary>
        public class SubmitMultipleRequest : GamesBaseServiceRequest<Google.Apis.Games.v1.Data.PlayerScoreListResponse>
        {
            /// <summary>Constructs a new SubmitMultiple request.</summary>
            public SubmitMultipleRequest(Google.Apis.Services.IClientService service, Google.Apis.Games.v1.Data.PlayerScoreSubmissionList body)
                : base(service)
            {
                Body = body;
                InitParameters();
            }


            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }

            /// <summary>The preferred language to use for strings returned by this method.</summary>
            [Google.Apis.Util.RequestParameterAttribute("language", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string Language { get; set; }


            /// <summary>Gets or sets the body of this request.</summary>
            Google.Apis.Games.v1.Data.PlayerScoreSubmissionList Body { get; set; }

            ///<summary>Returns the body of the request.</summary>
            protected override object GetBody() { return Body; }

            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "submitMultiple"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "POST"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "leaderboards/scores"; }
            }

            /// <summary>Initializes SubmitMultiple parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "language", new Google.Apis.Discovery.Parameter
                    {
                        Name = "language",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
            }

        }
    }

    /// <summary>The "snapshots" collection of methods.</summary>
    public class SnapshotsResource
    {
        private const string Resource = "snapshots";

        /// <summary>The service which this resource belongs to.</summary>
        private readonly Google.Apis.Services.IClientService service;

        /// <summary>Constructs a new resource.</summary>
        public SnapshotsResource(Google.Apis.Services.IClientService service)
        {
            this.service = service;

        }


        /// <summary>Retrieves the metadata for a given snapshot ID.</summary>
        /// <param name="snapshotId">The ID of the snapshot.</param>
        public virtual GetRequest Get(string snapshotId)
        {
            return new GetRequest(service, snapshotId);
        }

        /// <summary>Retrieves the metadata for a given snapshot ID.</summary>
        public class GetRequest : GamesBaseServiceRequest<Google.Apis.Games.v1.Data.Snapshot>
        {
            /// <summary>Constructs a new Get request.</summary>
            public GetRequest(Google.Apis.Services.IClientService service, string snapshotId)
                : base(service)
            {
                SnapshotId = snapshotId;
                InitParameters();
            }


            /// <summary>The ID of the snapshot.</summary>
            [Google.Apis.Util.RequestParameterAttribute("snapshotId", Google.Apis.Util.RequestParameterType.Path)]
            public virtual string SnapshotId { get; private set; }

            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }

            /// <summary>The preferred language to use for strings returned by this method.</summary>
            [Google.Apis.Util.RequestParameterAttribute("language", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string Language { get; set; }


            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "get"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "GET"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "snapshots/{snapshotId}"; }
            }

            /// <summary>Initializes Get parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "snapshotId", new Google.Apis.Discovery.Parameter
                    {
                        Name = "snapshotId",
                        IsRequired = true,
                        ParameterType = "path",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "language", new Google.Apis.Discovery.Parameter
                    {
                        Name = "language",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
            }

        }

        /// <summary>Retrieves a list of snapshots created by your application for the player corresponding to the
        /// player ID.</summary>
        /// <param name="playerId">A player ID. A value of me may be used in place of the authenticated player's
        /// ID.</param>
        public virtual ListRequest List(string playerId)
        {
            return new ListRequest(service, playerId);
        }

        /// <summary>Retrieves a list of snapshots created by your application for the player corresponding to the
        /// player ID.</summary>
        public class ListRequest : GamesBaseServiceRequest<Google.Apis.Games.v1.Data.SnapshotListResponse>
        {
            /// <summary>Constructs a new List request.</summary>
            public ListRequest(Google.Apis.Services.IClientService service, string playerId)
                : base(service)
            {
                PlayerId = playerId;
                InitParameters();
            }


            /// <summary>A player ID. A value of me may be used in place of the authenticated player's ID.</summary>
            [Google.Apis.Util.RequestParameterAttribute("playerId", Google.Apis.Util.RequestParameterType.Path)]
            public virtual string PlayerId { get; private set; }

            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }

            /// <summary>The preferred language to use for strings returned by this method.</summary>
            [Google.Apis.Util.RequestParameterAttribute("language", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string Language { get; set; }

            /// <summary>The maximum number of snapshot resources to return in the response, used for paging. For any
            /// response, the actual number of snapshot resources returned may be less than the specified
            /// maxResults.</summary>
            /// [minimum: 1]
            /// [maximum: 25]
            [Google.Apis.Util.RequestParameterAttribute("maxResults", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<int> MaxResults { get; set; }

            /// <summary>The token returned by the previous request.</summary>
            [Google.Apis.Util.RequestParameterAttribute("pageToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string PageToken { get; set; }


            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "list"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "GET"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "players/{playerId}/snapshots"; }
            }

            /// <summary>Initializes List parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "playerId", new Google.Apis.Discovery.Parameter
                    {
                        Name = "playerId",
                        IsRequired = true,
                        ParameterType = "path",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "language", new Google.Apis.Discovery.Parameter
                    {
                        Name = "language",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "maxResults", new Google.Apis.Discovery.Parameter
                    {
                        Name = "maxResults",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "pageToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "pageToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
            }

        }
    }

    /// <summary>The "turnBasedMatches" collection of methods.</summary>
    public class TurnBasedMatchesResource
    {
        private const string Resource = "turnBasedMatches";

        /// <summary>The service which this resource belongs to.</summary>
        private readonly Google.Apis.Services.IClientService service;

        /// <summary>Constructs a new resource.</summary>
        public TurnBasedMatchesResource(Google.Apis.Services.IClientService service)
        {
            this.service = service;

        }


        /// <summary>Cancel a turn-based match.</summary>
        /// <param name="matchId">The ID of the match.</param>
        public virtual CancelRequest Cancel(string matchId)
        {
            return new CancelRequest(service, matchId);
        }

        /// <summary>Cancel a turn-based match.</summary>
        public class CancelRequest : GamesBaseServiceRequest<string>
        {
            /// <summary>Constructs a new Cancel request.</summary>
            public CancelRequest(Google.Apis.Services.IClientService service, string matchId)
                : base(service)
            {
                MatchId = matchId;
                InitParameters();
            }


            /// <summary>The ID of the match.</summary>
            [Google.Apis.Util.RequestParameterAttribute("matchId", Google.Apis.Util.RequestParameterType.Path)]
            public virtual string MatchId { get; private set; }

            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }


            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "cancel"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "PUT"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "turnbasedmatches/{matchId}/cancel"; }
            }

            /// <summary>Initializes Cancel parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "matchId", new Google.Apis.Discovery.Parameter
                    {
                        Name = "matchId",
                        IsRequired = true,
                        ParameterType = "path",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
            }

        }

        /// <summary>Create a turn-based match.</summary>
        /// <param name="body">The body of the request.</param>
        public virtual CreateRequest Create(Google.Apis.Games.v1.Data.TurnBasedMatchCreateRequest body)
        {
            return new CreateRequest(service, body);
        }

        /// <summary>Create a turn-based match.</summary>
        public class CreateRequest : GamesBaseServiceRequest<Google.Apis.Games.v1.Data.TurnBasedMatch>
        {
            /// <summary>Constructs a new Create request.</summary>
            public CreateRequest(Google.Apis.Services.IClientService service, Google.Apis.Games.v1.Data.TurnBasedMatchCreateRequest body)
                : base(service)
            {
                Body = body;
                InitParameters();
            }


            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }

            /// <summary>The preferred language to use for strings returned by this method.</summary>
            [Google.Apis.Util.RequestParameterAttribute("language", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string Language { get; set; }


            /// <summary>Gets or sets the body of this request.</summary>
            Google.Apis.Games.v1.Data.TurnBasedMatchCreateRequest Body { get; set; }

            ///<summary>Returns the body of the request.</summary>
            protected override object GetBody() { return Body; }

            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "create"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "POST"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "turnbasedmatches/create"; }
            }

            /// <summary>Initializes Create parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "language", new Google.Apis.Discovery.Parameter
                    {
                        Name = "language",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
            }

        }

        /// <summary>Decline an invitation to play a turn-based match.</summary>
        /// <param name="matchId">The ID of the match.</param>
        public virtual DeclineRequest Decline(string matchId)
        {
            return new DeclineRequest(service, matchId);
        }

        /// <summary>Decline an invitation to play a turn-based match.</summary>
        public class DeclineRequest : GamesBaseServiceRequest<Google.Apis.Games.v1.Data.TurnBasedMatch>
        {
            /// <summary>Constructs a new Decline request.</summary>
            public DeclineRequest(Google.Apis.Services.IClientService service, string matchId)
                : base(service)
            {
                MatchId = matchId;
                InitParameters();
            }


            /// <summary>The ID of the match.</summary>
            [Google.Apis.Util.RequestParameterAttribute("matchId", Google.Apis.Util.RequestParameterType.Path)]
            public virtual string MatchId { get; private set; }

            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }

            /// <summary>The preferred language to use for strings returned by this method.</summary>
            [Google.Apis.Util.RequestParameterAttribute("language", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string Language { get; set; }


            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "decline"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "PUT"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "turnbasedmatches/{matchId}/decline"; }
            }

            /// <summary>Initializes Decline parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "matchId", new Google.Apis.Discovery.Parameter
                    {
                        Name = "matchId",
                        IsRequired = true,
                        ParameterType = "path",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "language", new Google.Apis.Discovery.Parameter
                    {
                        Name = "language",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
            }

        }

        /// <summary>Dismiss a turn-based match from the match list. The match will no longer show up in the list and
        /// will not generate notifications.</summary>
        /// <param name="matchId">The ID of the match.</param>
        public virtual DismissRequest Dismiss(string matchId)
        {
            return new DismissRequest(service, matchId);
        }

        /// <summary>Dismiss a turn-based match from the match list. The match will no longer show up in the list and
        /// will not generate notifications.</summary>
        public class DismissRequest : GamesBaseServiceRequest<string>
        {
            /// <summary>Constructs a new Dismiss request.</summary>
            public DismissRequest(Google.Apis.Services.IClientService service, string matchId)
                : base(service)
            {
                MatchId = matchId;
                InitParameters();
            }


            /// <summary>The ID of the match.</summary>
            [Google.Apis.Util.RequestParameterAttribute("matchId", Google.Apis.Util.RequestParameterType.Path)]
            public virtual string MatchId { get; private set; }

            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }


            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "dismiss"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "PUT"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "turnbasedmatches/{matchId}/dismiss"; }
            }

            /// <summary>Initializes Dismiss parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "matchId", new Google.Apis.Discovery.Parameter
                    {
                        Name = "matchId",
                        IsRequired = true,
                        ParameterType = "path",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
            }

        }

        /// <summary>Finish a turn-based match. Each player should make this call once, after all results are in. Only
        /// the player whose turn it is may make the first call to Finish, and can pass in the final match
        /// state.</summary>
        /// <param name="body">The body of the request.</param>
        /// <param name="matchId">The ID of the match.</param>
        public virtual FinishRequest Finish(Google.Apis.Games.v1.Data.TurnBasedMatchResults body, string matchId)
        {
            return new FinishRequest(service, body, matchId);
        }

        /// <summary>Finish a turn-based match. Each player should make this call once, after all results are in. Only
        /// the player whose turn it is may make the first call to Finish, and can pass in the final match
        /// state.</summary>
        public class FinishRequest : GamesBaseServiceRequest<Google.Apis.Games.v1.Data.TurnBasedMatch>
        {
            /// <summary>Constructs a new Finish request.</summary>
            public FinishRequest(Google.Apis.Services.IClientService service, Google.Apis.Games.v1.Data.TurnBasedMatchResults body, string matchId)
                : base(service)
            {
                MatchId = matchId;
                Body = body;
                InitParameters();
            }


            /// <summary>The ID of the match.</summary>
            [Google.Apis.Util.RequestParameterAttribute("matchId", Google.Apis.Util.RequestParameterType.Path)]
            public virtual string MatchId { get; private set; }

            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }

            /// <summary>The preferred language to use for strings returned by this method.</summary>
            [Google.Apis.Util.RequestParameterAttribute("language", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string Language { get; set; }


            /// <summary>Gets or sets the body of this request.</summary>
            Google.Apis.Games.v1.Data.TurnBasedMatchResults Body { get; set; }

            ///<summary>Returns the body of the request.</summary>
            protected override object GetBody() { return Body; }

            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "finish"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "PUT"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "turnbasedmatches/{matchId}/finish"; }
            }

            /// <summary>Initializes Finish parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "matchId", new Google.Apis.Discovery.Parameter
                    {
                        Name = "matchId",
                        IsRequired = true,
                        ParameterType = "path",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "language", new Google.Apis.Discovery.Parameter
                    {
                        Name = "language",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
            }

        }

        /// <summary>Get the data for a turn-based match.</summary>
        /// <param name="matchId">The ID of the match.</param>
        public virtual GetRequest Get(string matchId)
        {
            return new GetRequest(service, matchId);
        }

        /// <summary>Get the data for a turn-based match.</summary>
        public class GetRequest : GamesBaseServiceRequest<Google.Apis.Games.v1.Data.TurnBasedMatch>
        {
            /// <summary>Constructs a new Get request.</summary>
            public GetRequest(Google.Apis.Services.IClientService service, string matchId)
                : base(service)
            {
                MatchId = matchId;
                InitParameters();
            }


            /// <summary>The ID of the match.</summary>
            [Google.Apis.Util.RequestParameterAttribute("matchId", Google.Apis.Util.RequestParameterType.Path)]
            public virtual string MatchId { get; private set; }

            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }

            /// <summary>Get match data along with metadata.</summary>
            [Google.Apis.Util.RequestParameterAttribute("includeMatchData", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<bool> IncludeMatchData { get; set; }

            /// <summary>The preferred language to use for strings returned by this method.</summary>
            [Google.Apis.Util.RequestParameterAttribute("language", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string Language { get; set; }


            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "get"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "GET"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "turnbasedmatches/{matchId}"; }
            }

            /// <summary>Initializes Get parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "matchId", new Google.Apis.Discovery.Parameter
                    {
                        Name = "matchId",
                        IsRequired = true,
                        ParameterType = "path",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "includeMatchData", new Google.Apis.Discovery.Parameter
                    {
                        Name = "includeMatchData",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "language", new Google.Apis.Discovery.Parameter
                    {
                        Name = "language",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
            }

        }

        /// <summary>Join a turn-based match.</summary>
        /// <param name="matchId">The ID of the match.</param>
        public virtual JoinRequest Join(string matchId)
        {
            return new JoinRequest(service, matchId);
        }

        /// <summary>Join a turn-based match.</summary>
        public class JoinRequest : GamesBaseServiceRequest<Google.Apis.Games.v1.Data.TurnBasedMatch>
        {
            /// <summary>Constructs a new Join request.</summary>
            public JoinRequest(Google.Apis.Services.IClientService service, string matchId)
                : base(service)
            {
                MatchId = matchId;
                InitParameters();
            }


            /// <summary>The ID of the match.</summary>
            [Google.Apis.Util.RequestParameterAttribute("matchId", Google.Apis.Util.RequestParameterType.Path)]
            public virtual string MatchId { get; private set; }

            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }

            /// <summary>The preferred language to use for strings returned by this method.</summary>
            [Google.Apis.Util.RequestParameterAttribute("language", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string Language { get; set; }


            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "join"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "PUT"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "turnbasedmatches/{matchId}/join"; }
            }

            /// <summary>Initializes Join parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "matchId", new Google.Apis.Discovery.Parameter
                    {
                        Name = "matchId",
                        IsRequired = true,
                        ParameterType = "path",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "language", new Google.Apis.Discovery.Parameter
                    {
                        Name = "language",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
            }

        }

        /// <summary>Leave a turn-based match when it is not the current player's turn, without canceling the
        /// match.</summary>
        /// <param name="matchId">The ID of the match.</param>
        public virtual LeaveRequest Leave(string matchId)
        {
            return new LeaveRequest(service, matchId);
        }

        /// <summary>Leave a turn-based match when it is not the current player's turn, without canceling the
        /// match.</summary>
        public class LeaveRequest : GamesBaseServiceRequest<Google.Apis.Games.v1.Data.TurnBasedMatch>
        {
            /// <summary>Constructs a new Leave request.</summary>
            public LeaveRequest(Google.Apis.Services.IClientService service, string matchId)
                : base(service)
            {
                MatchId = matchId;
                InitParameters();
            }


            /// <summary>The ID of the match.</summary>
            [Google.Apis.Util.RequestParameterAttribute("matchId", Google.Apis.Util.RequestParameterType.Path)]
            public virtual string MatchId { get; private set; }

            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }

            /// <summary>The preferred language to use for strings returned by this method.</summary>
            [Google.Apis.Util.RequestParameterAttribute("language", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string Language { get; set; }


            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "leave"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "PUT"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "turnbasedmatches/{matchId}/leave"; }
            }

            /// <summary>Initializes Leave parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "matchId", new Google.Apis.Discovery.Parameter
                    {
                        Name = "matchId",
                        IsRequired = true,
                        ParameterType = "path",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "language", new Google.Apis.Discovery.Parameter
                    {
                        Name = "language",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
            }

        }

        /// <summary>Leave a turn-based match during the current player's turn, without canceling the match.</summary>
        /// <param name="matchId">The ID of the match.</param>
        /// <param name="matchVersion">The version of the match being
        /// updated.</param>
        public virtual LeaveTurnRequest LeaveTurn(string matchId, int matchVersion)
        {
            return new LeaveTurnRequest(service, matchId, matchVersion);
        }

        /// <summary>Leave a turn-based match during the current player's turn, without canceling the match.</summary>
        public class LeaveTurnRequest : GamesBaseServiceRequest<Google.Apis.Games.v1.Data.TurnBasedMatch>
        {
            /// <summary>Constructs a new LeaveTurn request.</summary>
            public LeaveTurnRequest(Google.Apis.Services.IClientService service, string matchId, int matchVersion)
                : base(service)
            {
                MatchId = matchId;
                MatchVersion = matchVersion;
                InitParameters();
            }


            /// <summary>The ID of the match.</summary>
            [Google.Apis.Util.RequestParameterAttribute("matchId", Google.Apis.Util.RequestParameterType.Path)]
            public virtual string MatchId { get; private set; }

            /// <summary>The version of the match being updated.</summary>
            [Google.Apis.Util.RequestParameterAttribute("matchVersion", Google.Apis.Util.RequestParameterType.Query)]
            public virtual int MatchVersion { get; private set; }

            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }

            /// <summary>The preferred language to use for strings returned by this method.</summary>
            [Google.Apis.Util.RequestParameterAttribute("language", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string Language { get; set; }

            /// <summary>The ID of another participant who should take their turn next. If not set, the match will wait
            /// for other player(s) to join via automatching; this is only valid if automatch criteria is set on the
            /// match with remaining slots for automatched players.</summary>
            [Google.Apis.Util.RequestParameterAttribute("pendingParticipantId", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string PendingParticipantId { get; set; }


            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "leaveTurn"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "PUT"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "turnbasedmatches/{matchId}/leaveTurn"; }
            }

            /// <summary>Initializes LeaveTurn parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "matchId", new Google.Apis.Discovery.Parameter
                    {
                        Name = "matchId",
                        IsRequired = true,
                        ParameterType = "path",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "matchVersion", new Google.Apis.Discovery.Parameter
                    {
                        Name = "matchVersion",
                        IsRequired = true,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "language", new Google.Apis.Discovery.Parameter
                    {
                        Name = "language",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "pendingParticipantId", new Google.Apis.Discovery.Parameter
                    {
                        Name = "pendingParticipantId",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
            }

        }

        /// <summary>Returns turn-based matches the player is or was involved in.</summary>
        public virtual ListRequest List()
        {
            return new ListRequest(service);
        }

        /// <summary>Returns turn-based matches the player is or was involved in.</summary>
        public class ListRequest : GamesBaseServiceRequest<Google.Apis.Games.v1.Data.TurnBasedMatchList>
        {
            /// <summary>Constructs a new List request.</summary>
            public ListRequest(Google.Apis.Services.IClientService service)
                : base(service)
            {
                InitParameters();
            }


            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }

            /// <summary>True if match data should be returned in the response. Note that not all data will necessarily
            /// be returned if include_match_data is true; the server may decide to only return data for some of the
            /// matches to limit download size for the client. The remainder of the data for these matches will be
            /// retrievable on request.</summary>
            [Google.Apis.Util.RequestParameterAttribute("includeMatchData", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<bool> IncludeMatchData { get; set; }

            /// <summary>The preferred language to use for strings returned by this method.</summary>
            [Google.Apis.Util.RequestParameterAttribute("language", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string Language { get; set; }

            /// <summary>The maximum number of completed or canceled matches to return in the response. If not set, all
            /// matches returned could be completed or canceled.</summary>
            /// [minimum: 0]
            /// [maximum: 500]
            [Google.Apis.Util.RequestParameterAttribute("maxCompletedMatches", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<int> MaxCompletedMatches { get; set; }

            /// <summary>The maximum number of matches to return in the response, used for paging. For any response, the
            /// actual number of matches to return may be less than the specified maxResults.</summary>
            /// [minimum: 1]
            /// [maximum: 500]
            [Google.Apis.Util.RequestParameterAttribute("maxResults", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<int> MaxResults { get; set; }

            /// <summary>The token returned by the previous request.</summary>
            [Google.Apis.Util.RequestParameterAttribute("pageToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string PageToken { get; set; }


            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "list"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "GET"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "turnbasedmatches"; }
            }

            /// <summary>Initializes List parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "includeMatchData", new Google.Apis.Discovery.Parameter
                    {
                        Name = "includeMatchData",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "language", new Google.Apis.Discovery.Parameter
                    {
                        Name = "language",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "maxCompletedMatches", new Google.Apis.Discovery.Parameter
                    {
                        Name = "maxCompletedMatches",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "maxResults", new Google.Apis.Discovery.Parameter
                    {
                        Name = "maxResults",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "pageToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "pageToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
            }

        }

        /// <summary>Create a rematch of a match that was previously completed, with the same participants. This can be
        /// called by only one player on a match still in their list; the player must have called Finish first. Returns
        /// the newly created match; it will be the caller's turn.</summary>
        /// <param name="matchId">The ID of the match.</param>
        public virtual RematchRequest Rematch(string matchId)
        {
            return new RematchRequest(service, matchId);
        }

        /// <summary>Create a rematch of a match that was previously completed, with the same participants. This can be
        /// called by only one player on a match still in their list; the player must have called Finish first. Returns
        /// the newly created match; it will be the caller's turn.</summary>
        public class RematchRequest : GamesBaseServiceRequest<Google.Apis.Games.v1.Data.TurnBasedMatchRematch>
        {
            /// <summary>Constructs a new Rematch request.</summary>
            public RematchRequest(Google.Apis.Services.IClientService service, string matchId)
                : base(service)
            {
                MatchId = matchId;
                InitParameters();
            }


            /// <summary>The ID of the match.</summary>
            [Google.Apis.Util.RequestParameterAttribute("matchId", Google.Apis.Util.RequestParameterType.Path)]
            public virtual string MatchId { get; private set; }

            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }

            /// <summary>The preferred language to use for strings returned by this method.</summary>
            [Google.Apis.Util.RequestParameterAttribute("language", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string Language { get; set; }

            /// <summary>A randomly generated numeric ID for each request specified by the caller. This number is used
            /// at the server to ensure that the request is handled correctly across retries.</summary>
            [Google.Apis.Util.RequestParameterAttribute("requestId", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> RequestId { get; set; }


            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "rematch"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "POST"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "turnbasedmatches/{matchId}/rematch"; }
            }

            /// <summary>Initializes Rematch parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "matchId", new Google.Apis.Discovery.Parameter
                    {
                        Name = "matchId",
                        IsRequired = true,
                        ParameterType = "path",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "language", new Google.Apis.Discovery.Parameter
                    {
                        Name = "language",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "requestId", new Google.Apis.Discovery.Parameter
                    {
                        Name = "requestId",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
            }

        }

        /// <summary>Returns turn-based matches the player is or was involved in that changed since the last sync call,
        /// with the least recent changes coming first. Matches that should be removed from the local cache will have a
        /// status of MATCH_DELETED.</summary>
        public virtual SyncRequest Sync()
        {
            return new SyncRequest(service);
        }

        /// <summary>Returns turn-based matches the player is or was involved in that changed since the last sync call,
        /// with the least recent changes coming first. Matches that should be removed from the local cache will have a
        /// status of MATCH_DELETED.</summary>
        public class SyncRequest : GamesBaseServiceRequest<Google.Apis.Games.v1.Data.TurnBasedMatchSync>
        {
            /// <summary>Constructs a new Sync request.</summary>
            public SyncRequest(Google.Apis.Services.IClientService service)
                : base(service)
            {
                InitParameters();
            }


            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }

            /// <summary>True if match data should be returned in the response. Note that not all data will necessarily
            /// be returned if include_match_data is true; the server may decide to only return data for some of the
            /// matches to limit download size for the client. The remainder of the data for these matches will be
            /// retrievable on request.</summary>
            [Google.Apis.Util.RequestParameterAttribute("includeMatchData", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<bool> IncludeMatchData { get; set; }

            /// <summary>The preferred language to use for strings returned by this method.</summary>
            [Google.Apis.Util.RequestParameterAttribute("language", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string Language { get; set; }

            /// <summary>The maximum number of completed or canceled matches to return in the response. If not set, all
            /// matches returned could be completed or canceled.</summary>
            /// [minimum: 0]
            /// [maximum: 500]
            [Google.Apis.Util.RequestParameterAttribute("maxCompletedMatches", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<int> MaxCompletedMatches { get; set; }

            /// <summary>The maximum number of matches to return in the response, used for paging. For any response, the
            /// actual number of matches to return may be less than the specified maxResults.</summary>
            /// [minimum: 1]
            /// [maximum: 500]
            [Google.Apis.Util.RequestParameterAttribute("maxResults", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<int> MaxResults { get; set; }

            /// <summary>The token returned by the previous request.</summary>
            [Google.Apis.Util.RequestParameterAttribute("pageToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string PageToken { get; set; }


            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "sync"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "GET"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "turnbasedmatches/sync"; }
            }

            /// <summary>Initializes Sync parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "includeMatchData", new Google.Apis.Discovery.Parameter
                    {
                        Name = "includeMatchData",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "language", new Google.Apis.Discovery.Parameter
                    {
                        Name = "language",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "maxCompletedMatches", new Google.Apis.Discovery.Parameter
                    {
                        Name = "maxCompletedMatches",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "maxResults", new Google.Apis.Discovery.Parameter
                    {
                        Name = "maxResults",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "pageToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "pageToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
            }

        }

        /// <summary>Commit the results of a player turn.</summary>
        /// <param name="body">The body of the request.</param>
        /// <param name="matchId">The ID of the match.</param>
        public virtual TakeTurnRequest TakeTurn(Google.Apis.Games.v1.Data.TurnBasedMatchTurn body, string matchId)
        {
            return new TakeTurnRequest(service, body, matchId);
        }

        /// <summary>Commit the results of a player turn.</summary>
        public class TakeTurnRequest : GamesBaseServiceRequest<Google.Apis.Games.v1.Data.TurnBasedMatch>
        {
            /// <summary>Constructs a new TakeTurn request.</summary>
            public TakeTurnRequest(Google.Apis.Services.IClientService service, Google.Apis.Games.v1.Data.TurnBasedMatchTurn body, string matchId)
                : base(service)
            {
                MatchId = matchId;
                Body = body;
                InitParameters();
            }


            /// <summary>The ID of the match.</summary>
            [Google.Apis.Util.RequestParameterAttribute("matchId", Google.Apis.Util.RequestParameterType.Path)]
            public virtual string MatchId { get; private set; }

            /// <summary>The last-seen mutation timestamp.</summary>
            [Google.Apis.Util.RequestParameterAttribute("consistencyToken", Google.Apis.Util.RequestParameterType.Query)]
            public virtual System.Nullable<long> ConsistencyToken { get; set; }

            /// <summary>The preferred language to use for strings returned by this method.</summary>
            [Google.Apis.Util.RequestParameterAttribute("language", Google.Apis.Util.RequestParameterType.Query)]
            public virtual string Language { get; set; }


            /// <summary>Gets or sets the body of this request.</summary>
            Google.Apis.Games.v1.Data.TurnBasedMatchTurn Body { get; set; }

            ///<summary>Returns the body of the request.</summary>
            protected override object GetBody() { return Body; }

            ///<summary>Gets the method name.</summary>
            public override string MethodName
            {
                get { return "takeTurn"; }
            }

            ///<summary>Gets the HTTP method.</summary>
            public override string HttpMethod
            {
                get { return "PUT"; }
            }

            ///<summary>Gets the REST path.</summary>
            public override string RestPath
            {
                get { return "turnbasedmatches/{matchId}/turn"; }
            }

            /// <summary>Initializes TakeTurn parameter list.</summary>
            protected override void InitParameters()
            {
                base.InitParameters();

                RequestParameters.Add(
                    "matchId", new Google.Apis.Discovery.Parameter
                    {
                        Name = "matchId",
                        IsRequired = true,
                        ParameterType = "path",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "consistencyToken", new Google.Apis.Discovery.Parameter
                    {
                        Name = "consistencyToken",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
                RequestParameters.Add(
                    "language", new Google.Apis.Discovery.Parameter
                    {
                        Name = "language",
                        IsRequired = false,
                        ParameterType = "query",
                        DefaultValue = null,
                        Pattern = null,
                    });
            }

        }
    }
}

namespace Google.Apis.Games.v1.Data
{    

    /// <summary>This is a JSON template for an achievement definition object.</summary>
    public class AchievementDefinition : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The type of the achievement. Possible values are: - "STANDARD" - Achievement is either locked or
        /// unlocked. - "INCREMENTAL" - Achievement is incremental.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("achievementType")]
        public virtual string AchievementType { get; set; } 

        /// <summary>The description of the achievement.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("description")]
        public virtual string Description { get; set; } 

        /// <summary>Experience points which will be earned when unlocking this achievement.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("experiencePoints")]
        public virtual System.Nullable<long> ExperiencePoints { get; set; } 

        /// <summary>The total steps for an incremental achievement as a string.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("formattedTotalSteps")]
        public virtual string FormattedTotalSteps { get; set; } 

        /// <summary>The ID of the achievement.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("id")]
        public virtual string Id { get; set; } 

        /// <summary>The initial state of the achievement. Possible values are: - "HIDDEN" - Achievement is hidden. -
        /// "REVEALED" - Achievement is revealed. - "UNLOCKED" - Achievement is unlocked.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("initialState")]
        public virtual string InitialState { get; set; } 

        /// <summary>Indicates whether the revealed icon image being returned is a default image, or is provided by the
        /// game.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("isRevealedIconUrlDefault")]
        public virtual System.Nullable<bool> IsRevealedIconUrlDefault { get; set; } 

        /// <summary>Indicates whether the unlocked icon image being returned is a default image, or is game-
        /// provided.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("isUnlockedIconUrlDefault")]
        public virtual System.Nullable<bool> IsUnlockedIconUrlDefault { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#achievementDefinition.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The name of the achievement.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("name")]
        public virtual string Name { get; set; } 

        /// <summary>The image URL for the revealed achievement icon.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("revealedIconUrl")]
        public virtual string RevealedIconUrl { get; set; } 

        /// <summary>The total steps for an incremental achievement.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("totalSteps")]
        public virtual System.Nullable<int> TotalSteps { get; set; } 

        /// <summary>The image URL for the unlocked achievement icon.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("unlockedIconUrl")]
        public virtual string UnlockedIconUrl { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for a list of achievement definition objects.</summary>
    public class AchievementDefinitionsListResponse : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The achievement definitions.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("items")]
        public virtual System.Collections.Generic.IList<AchievementDefinition> Items { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#achievementDefinitionsListResponse.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>Token corresponding to the next page of results.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("nextPageToken")]
        public virtual string NextPageToken { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for an achievement increment response</summary>
    public class AchievementIncrementResponse : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The current steps recorded for this incremental achievement.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("currentSteps")]
        public virtual System.Nullable<int> CurrentSteps { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#achievementIncrementResponse.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>Whether the current steps for the achievement has reached the number of steps required to
        /// unlock.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("newlyUnlocked")]
        public virtual System.Nullable<bool> NewlyUnlocked { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for an achievement reveal response</summary>
    public class AchievementRevealResponse : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The current state of the achievement for which a reveal was attempted. This might be UNLOCKED if
        /// the achievement was already unlocked. Possible values are: - "REVEALED" - Achievement is revealed. -
        /// "UNLOCKED" - Achievement is unlocked.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("currentState")]
        public virtual string CurrentState { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#achievementRevealResponse.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for an achievement set steps at least response.</summary>
    public class AchievementSetStepsAtLeastResponse : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The current steps recorded for this incremental achievement.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("currentSteps")]
        public virtual System.Nullable<int> CurrentSteps { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#achievementSetStepsAtLeastResponse.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>Whether the the current steps for the achievement has reached the number of steps required to
        /// unlock.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("newlyUnlocked")]
        public virtual System.Nullable<bool> NewlyUnlocked { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for an achievement unlock response</summary>
    public class AchievementUnlockResponse : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#achievementUnlockResponse.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>Whether this achievement was newly unlocked (that is, whether the unlock request for the
        /// achievement was the first for the player).</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("newlyUnlocked")]
        public virtual System.Nullable<bool> NewlyUnlocked { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for a list of achievement update requests.</summary>
    public class AchievementUpdateMultipleRequest : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#achievementUpdateMultipleRequest.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The individual achievement update requests.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("updates")]
        public virtual System.Collections.Generic.IList<AchievementUpdateRequest> Updates { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for an achievement unlock response.</summary>
    public class AchievementUpdateMultipleResponse : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#achievementUpdateListResponse.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The updated state of the achievements.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("updatedAchievements")]
        public virtual System.Collections.Generic.IList<AchievementUpdateResponse> UpdatedAchievements { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for a request to update an achievement.</summary>
    public class AchievementUpdateRequest : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The achievement this update is being applied to.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("achievementId")]
        public virtual string AchievementId { get; set; } 

        /// <summary>The payload if an update of type INCREMENT was requested for the achievement.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("incrementPayload")]
        public virtual GamesAchievementIncrement IncrementPayload { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#achievementUpdateRequest.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The payload if an update of type SET_STEPS_AT_LEAST was requested for the achievement.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("setStepsAtLeastPayload")]
        public virtual GamesAchievementSetStepsAtLeast SetStepsAtLeastPayload { get; set; } 

        /// <summary>The type of update being applied. Possible values are: - "REVEAL" - Achievement is revealed. -
        /// "UNLOCK" - Achievement is unlocked. - "INCREMENT" - Achievement is incremented. - "SET_STEPS_AT_LEAST" -
        /// Achievement progress is set to at least the passed value.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("updateType")]
        public virtual string UpdateType { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for an achievement update response.</summary>
    public class AchievementUpdateResponse : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The achievement this update is was applied to.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("achievementId")]
        public virtual string AchievementId { get; set; } 

        /// <summary>The current state of the achievement. Possible values are: - "HIDDEN" - Achievement is hidden. -
        /// "REVEALED" - Achievement is revealed. - "UNLOCKED" - Achievement is unlocked.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("currentState")]
        public virtual string CurrentState { get; set; } 

        /// <summary>The current steps recorded for this achievement if it is incremental.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("currentSteps")]
        public virtual System.Nullable<int> CurrentSteps { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#achievementUpdateResponse.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>Whether this achievement was newly unlocked (that is, whether the unlock request for the
        /// achievement was the first for the player).</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("newlyUnlocked")]
        public virtual System.Nullable<bool> NewlyUnlocked { get; set; } 

        /// <summary>Whether the requested updates actually affected the achievement.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("updateOccurred")]
        public virtual System.Nullable<bool> UpdateOccurred { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for aggregate stats.</summary>
    public class AggregateStats : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The number of messages sent between a pair of peers.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("count")]
        public virtual System.Nullable<long> Count { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#aggregateStats.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The maximum amount.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("max")]
        public virtual System.Nullable<long> Max { get; set; } 

        /// <summary>The minimum amount.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("min")]
        public virtual System.Nullable<long> Min { get; set; } 

        /// <summary>The total number of bytes sent for messages between a pair of peers.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("sum")]
        public virtual System.Nullable<long> Sum { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for an anonymous player</summary>
    public class AnonymousPlayer : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The base URL for the image to display for the anonymous player.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("avatarImageUrl")]
        public virtual string AvatarImageUrl { get; set; } 

        /// <summary>The name to display for the anonymous player.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("displayName")]
        public virtual string DisplayName { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#anonymousPlayer.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for the Application resource.</summary>
    public class Application : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The number of achievements visible to the currently authenticated player.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("achievement_count")]
        public virtual System.Nullable<int> AchievementCount { get; set; } 

        /// <summary>The assets of the application.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("assets")]
        public virtual System.Collections.Generic.IList<ImageAsset> Assets { get; set; } 

        /// <summary>The author of the application.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("author")]
        public virtual string Author { get; set; } 

        /// <summary>The category of the application.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("category")]
        public virtual ApplicationCategory Category { get; set; } 

        /// <summary>The description of the application.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("description")]
        public virtual string Description { get; set; } 

        /// <summary>A list of features that have been enabled for the application. Possible values are: - "SNAPSHOTS" -
        /// Snapshots has been enabled</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("enabledFeatures")]
        public virtual System.Collections.Generic.IList<string> EnabledFeatures { get; set; } 

        /// <summary>The ID of the application.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("id")]
        public virtual string Id { get; set; } 

        /// <summary>The instances of the application.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("instances")]
        public virtual System.Collections.Generic.IList<Instance> Instances { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#application.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The last updated timestamp of the application.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("lastUpdatedTimestamp")]
        public virtual System.Nullable<long> LastUpdatedTimestamp { get; set; } 

        /// <summary>The number of leaderboards visible to the currently authenticated player.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("leaderboard_count")]
        public virtual System.Nullable<int> LeaderboardCount { get; set; } 

        /// <summary>The name of the application.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("name")]
        public virtual string Name { get; set; } 

        /// <summary>A hint to the client UI for what color to use as an app-themed color. The color is given as an RGB
        /// triplet (e.g. "E0E0E0").</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("themeColor")]
        public virtual string ThemeColor { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for an application category object.</summary>
    public class ApplicationCategory : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#applicationCategory.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The primary category.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("primary")]
        public virtual string Primary { get; set; } 

        /// <summary>The secondary category.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("secondary")]
        public virtual string Secondary { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for a third party application verification response resource.</summary>
    public class ApplicationVerifyResponse : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>An alternate ID that was once used for the player that was issued the auth token used in this
        /// request. (This field is not normally populated.)</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("alternate_player_id")]
        public virtual string AlternatePlayerId { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#applicationVerifyResponse.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The ID of the player that was issued the auth token used in this request.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("player_id")]
        public virtual string PlayerId { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for data related to individual game categories.</summary>
    public class Category : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The category name.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("category")]
        public virtual string CategoryValue { get; set; } 

        /// <summary>Experience points earned in this category.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("experiencePoints")]
        public virtual System.Nullable<long> ExperiencePoints { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#category.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for a list of category data objects.</summary>
    public class CategoryListResponse : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The list of categories with usage data.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("items")]
        public virtual System.Collections.Generic.IList<Category> Items { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#categoryListResponse.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>Token corresponding to the next page of results.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("nextPageToken")]
        public virtual string NextPageToken { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for a batch update failure resource.</summary>
    public class EventBatchRecordFailure : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The cause for the update failure. Possible values are: - "TOO_LARGE": A batch request was issued
        /// with more events than are allowed in a single batch. - "TIME_PERIOD_EXPIRED": A batch was sent with data too
        /// far in the past to record. - "TIME_PERIOD_SHORT": A batch was sent with a time range that was too short. -
        /// "TIME_PERIOD_LONG": A batch was sent with a time range that was too long. - "ALREADY_UPDATED": An attempt
        /// was made to record a batch of data which was already seen. - "RECORD_RATE_HIGH": An attempt was made to
        /// record data faster than the server will apply updates.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("failureCause")]
        public virtual string FailureCause { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#eventBatchRecordFailure.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The time range which was rejected; empty for a request-wide failure.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("range")]
        public virtual EventPeriodRange Range { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for an event child relationship resource.</summary>
    public class EventChild : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The ID of the child event.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("childId")]
        public virtual string ChildId { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#eventChild.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for an event definition resource.</summary>
    public class EventDefinition : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>A list of events that are a child of this event.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("childEvents")]
        public virtual System.Collections.Generic.IList<EventChild> ChildEvents { get; set; } 

        /// <summary>Description of what this event represents.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("description")]
        public virtual string Description { get; set; } 

        /// <summary>The name to display for the event.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("displayName")]
        public virtual string DisplayName { get; set; } 

        /// <summary>The ID of the event.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("id")]
        public virtual string Id { get; set; } 

        /// <summary>The base URL for the image that represents the event.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("imageUrl")]
        public virtual string ImageUrl { get; set; } 

        /// <summary>Indicates whether the icon image being returned is a default image, or is game-provided.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("isDefaultImageUrl")]
        public virtual System.Nullable<bool> IsDefaultImageUrl { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#eventDefinition.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The visibility of event being tracked in this definition. Possible values are: - "REVEALED": This
        /// event should be visible to all users. - "HIDDEN": This event should only be shown to users that have
        /// recorded this event at least once.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("visibility")]
        public virtual string Visibility { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for a ListDefinitions response.</summary>
    public class EventDefinitionListResponse : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The event definitions.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("items")]
        public virtual System.Collections.Generic.IList<EventDefinition> Items { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#eventDefinitionListResponse.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The pagination token for the next page of results.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("nextPageToken")]
        public virtual string NextPageToken { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for an event period time range.</summary>
    public class EventPeriodRange : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#eventPeriodRange.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The time when this update period ends, in millis, since 1970 UTC (Unix Epoch).</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("periodEndMillis")]
        public virtual System.Nullable<long> PeriodEndMillis { get; set; } 

        /// <summary>The time when this update period begins, in millis, since 1970 UTC (Unix Epoch).</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("periodStartMillis")]
        public virtual System.Nullable<long> PeriodStartMillis { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for an event period update resource.</summary>
    public class EventPeriodUpdate : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#eventPeriodUpdate.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The time period being covered by this update.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("timePeriod")]
        public virtual EventPeriodRange TimePeriod { get; set; } 

        /// <summary>The updates being made for this time period.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("updates")]
        public virtual System.Collections.Generic.IList<EventUpdateRequest> Updates { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for an event update failure resource.</summary>
    public class EventRecordFailure : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The ID of the event that was not updated.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("eventId")]
        public virtual string EventId { get; set; } 

        /// <summary>The cause for the update failure. Possible values are: - "NOT_FOUND" - An attempt was made to set
        /// an event that was not defined. - "INVALID_UPDATE_VALUE" - An attempt was made to increment an event by a
        /// non-positive value.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("failureCause")]
        public virtual string FailureCause { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#eventRecordFailure.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for an event period update resource.</summary>
    public class EventRecordRequest : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The current time when this update was sent, in milliseconds, since 1970 UTC (Unix Epoch).</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("currentTimeMillis")]
        public virtual System.Nullable<long> CurrentTimeMillis { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#eventRecordRequest.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The request ID used to identify this attempt to record events.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("requestId")]
        public virtual System.Nullable<long> RequestId { get; set; } 

        /// <summary>A list of the time period updates being made in this request.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("timePeriods")]
        public virtual System.Collections.Generic.IList<EventPeriodUpdate> TimePeriods { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for an event period update resource.</summary>
    public class EventUpdateRequest : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The ID of the event being modified in this update.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("definitionId")]
        public virtual string DefinitionId { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#eventUpdateRequest.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The number of times this event occurred in this time period.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("updateCount")]
        public virtual System.Nullable<long> UpdateCount { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for an event period update resource.</summary>
    public class EventUpdateResponse : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>Any batch-wide failures which occurred applying updates.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("batchFailures")]
        public virtual System.Collections.Generic.IList<EventBatchRecordFailure> BatchFailures { get; set; } 

        /// <summary>Any failures updating a particular event.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("eventFailures")]
        public virtual System.Collections.Generic.IList<EventRecordFailure> EventFailures { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#eventUpdateResponse.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The current status of any updated events</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("playerEvents")]
        public virtual System.Collections.Generic.IList<PlayerEvent> PlayerEvents { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for the payload to request to increment an achievement.</summary>
    public class GamesAchievementIncrement : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#GamesAchievementIncrement.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The requestId associated with an increment to an achievement.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("requestId")]
        public virtual System.Nullable<long> RequestId { get; set; } 

        /// <summary>The number of steps to be incremented.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("steps")]
        public virtual System.Nullable<int> Steps { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for the payload to request to increment an achievement.</summary>
    public class GamesAchievementSetStepsAtLeast : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#GamesAchievementSetStepsAtLeast.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The minimum number of steps for the achievement to be set to.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("steps")]
        public virtual System.Nullable<int> Steps { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for an image asset object.</summary>
    public class ImageAsset : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The height of the asset.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("height")]
        public virtual System.Nullable<int> Height { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#imageAsset.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The name of the asset.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("name")]
        public virtual string Name { get; set; } 

        /// <summary>The URL of the asset.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("url")]
        public virtual string Url { get; set; } 

        /// <summary>The width of the asset.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("width")]
        public virtual System.Nullable<int> Width { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for the Instance resource.</summary>
    public class Instance : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>URI which shows where a user can acquire this instance.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("acquisitionUri")]
        public virtual string AcquisitionUri { get; set; } 

        /// <summary>Platform dependent details for Android.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("androidInstance")]
        public virtual InstanceAndroidDetails AndroidInstance { get; set; } 

        /// <summary>Platform dependent details for iOS.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("iosInstance")]
        public virtual InstanceIosDetails IosInstance { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#instance.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>Localized display name.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("name")]
        public virtual string Name { get; set; } 

        /// <summary>The platform type. Possible values are: - "ANDROID" - Instance is for Android. - "IOS" - Instance
        /// is for iOS - "WEB_APP" - Instance is for Web App.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("platformType")]
        public virtual string PlatformType { get; set; } 

        /// <summary>Flag to show if this game instance supports realtime play.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("realtimePlay")]
        public virtual System.Nullable<bool> RealtimePlay { get; set; } 

        /// <summary>Flag to show if this game instance supports turn based play.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("turnBasedPlay")]
        public virtual System.Nullable<bool> TurnBasedPlay { get; set; } 

        /// <summary>Platform dependent details for Web.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("webInstance")]
        public virtual InstanceWebDetails WebInstance { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for the Android instance details resource.</summary>
    public class InstanceAndroidDetails : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>Flag indicating whether the anti-piracy check is enabled.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("enablePiracyCheck")]
        public virtual System.Nullable<bool> EnablePiracyCheck { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#instanceAndroidDetails.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>Android package name which maps to Google Play URL.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("packageName")]
        public virtual string PackageName { get; set; } 

        /// <summary>Indicates that this instance is the default for new installations.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("preferred")]
        public virtual System.Nullable<bool> Preferred { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for the iOS details resource.</summary>
    public class InstanceIosDetails : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>Bundle identifier.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("bundleIdentifier")]
        public virtual string BundleIdentifier { get; set; } 

        /// <summary>iTunes App ID.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("itunesAppId")]
        public virtual string ItunesAppId { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#instanceIosDetails.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>Indicates that this instance is the default for new installations on iPad devices.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("preferredForIpad")]
        public virtual System.Nullable<bool> PreferredForIpad { get; set; } 

        /// <summary>Indicates that this instance is the default for new installations on iPhone devices.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("preferredForIphone")]
        public virtual System.Nullable<bool> PreferredForIphone { get; set; } 

        /// <summary>Flag to indicate if this instance supports iPad.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("supportIpad")]
        public virtual System.Nullable<bool> SupportIpad { get; set; } 

        /// <summary>Flag to indicate if this instance supports iPhone.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("supportIphone")]
        public virtual System.Nullable<bool> SupportIphone { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for the Web details resource.</summary>
    public class InstanceWebDetails : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#instanceWebDetails.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>Launch URL for the game.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("launchUrl")]
        public virtual string LaunchUrl { get; set; } 

        /// <summary>Indicates that this instance is the default for new installations.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("preferred")]
        public virtual System.Nullable<bool> Preferred { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for the Leaderboard resource.</summary>
    public class Leaderboard : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The icon for the leaderboard.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("iconUrl")]
        public virtual string IconUrl { get; set; } 

        /// <summary>The leaderboard ID.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("id")]
        public virtual string Id { get; set; } 

        /// <summary>Indicates whether the icon image being returned is a default image, or is game-provided.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("isIconUrlDefault")]
        public virtual System.Nullable<bool> IsIconUrlDefault { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#leaderboard.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The name of the leaderboard.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("name")]
        public virtual string Name { get; set; } 

        /// <summary>How scores are ordered. Possible values are: - "LARGER_IS_BETTER" - Larger values are better;
        /// scores are sorted in descending order. - "SMALLER_IS_BETTER" - Smaller values are better; scores are sorted
        /// in ascending order.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("order")]
        public virtual string Order { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for the Leaderboard Entry resource.</summary>
    public class LeaderboardEntry : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The localized string for the numerical value of this score.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("formattedScore")]
        public virtual string FormattedScore { get; set; } 

        /// <summary>The localized string for the rank of this score for this leaderboard.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("formattedScoreRank")]
        public virtual string FormattedScoreRank { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#leaderboardEntry.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The player who holds this score.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("player")]
        public virtual Player Player { get; set; } 

        /// <summary>The rank of this score for this leaderboard.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("scoreRank")]
        public virtual System.Nullable<long> ScoreRank { get; set; } 

        /// <summary>Additional information about the score. Values must contain no more than 64 URI-safe characters as
        /// defined by section 2.3 of RFC 3986.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("scoreTag")]
        public virtual string ScoreTag { get; set; } 

        /// <summary>The numerical value of this score.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("scoreValue")]
        public virtual System.Nullable<long> ScoreValue { get; set; } 

        /// <summary>The time span of this high score. Possible values are: - "ALL_TIME" - The score is an all-time high
        /// score. - "WEEKLY" - The score is a weekly high score. - "DAILY" - The score is a daily high score.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("timeSpan")]
        public virtual string TimeSpan { get; set; } 

        /// <summary>The timestamp at which this score was recorded, in milliseconds since the epoch in UTC.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("writeTimestampMillis")]
        public virtual System.Nullable<long> WriteTimestampMillis { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for a list of leaderboard objects.</summary>
    public class LeaderboardListResponse : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The leaderboards.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("items")]
        public virtual System.Collections.Generic.IList<Leaderboard> Items { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#leaderboardListResponse.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>Token corresponding to the next page of results.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("nextPageToken")]
        public virtual string NextPageToken { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for a score rank in a leaderboard.</summary>
    public class LeaderboardScoreRank : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The number of scores in the leaderboard as a string.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("formattedNumScores")]
        public virtual string FormattedNumScores { get; set; } 

        /// <summary>The rank in the leaderboard as a string.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("formattedRank")]
        public virtual string FormattedRank { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#leaderboardScoreRank.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The number of scores in the leaderboard.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("numScores")]
        public virtual System.Nullable<long> NumScores { get; set; } 

        /// <summary>The rank in the leaderboard.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("rank")]
        public virtual System.Nullable<long> Rank { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for a ListScores response.</summary>
    public class LeaderboardScores : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The scores in the leaderboard.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("items")]
        public virtual System.Collections.Generic.IList<LeaderboardEntry> Items { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#leaderboardScores.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The pagination token for the next page of results.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("nextPageToken")]
        public virtual string NextPageToken { get; set; } 

        /// <summary>The total number of scores in the leaderboard.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("numScores")]
        public virtual System.Nullable<long> NumScores { get; set; } 

        /// <summary>The score of the requesting player on the leaderboard. The player's score may appear both here and
        /// in the list of scores above. If you are viewing a public leaderboard and the player is not sharing their
        /// gameplay information publicly, the scoreRank and formattedScoreRank values will not be present.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("playerScore")]
        public virtual LeaderboardEntry PlayerScore { get; set; } 

        /// <summary>The pagination token for the previous page of results.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("prevPageToken")]
        public virtual string PrevPageToken { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for the metagame config resource</summary>
    public class MetagameConfig : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>Current version of the metagame configuration data. When this data is updated, the version number
        /// will be increased by one.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("currentVersion")]
        public virtual System.Nullable<int> CurrentVersion { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#metagameConfig.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The list of player levels.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("playerLevels")]
        public virtual System.Collections.Generic.IList<PlayerLevel> PlayerLevels { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for network diagnostics reported for a client.</summary>
    public class NetworkDiagnostics : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The Android network subtype.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("androidNetworkSubtype")]
        public virtual System.Nullable<int> AndroidNetworkSubtype { get; set; } 

        /// <summary>The Android network type.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("androidNetworkType")]
        public virtual System.Nullable<int> AndroidNetworkType { get; set; } 

        /// <summary>iOS network type as defined in Reachability.h.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("iosNetworkType")]
        public virtual System.Nullable<int> IosNetworkType { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#networkDiagnostics.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The MCC+MNC code for the client's network connection. On Android:
        /// http://developer.android.com/reference/android/telephony/TelephonyManager.html#getNetworkOperator() On iOS,
        /// see: https://developer.apple.com/library/ios/documentation/NetworkingInternet/Reference/CTCarrier/Reference/
        /// Reference.html</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("networkOperatorCode")]
        public virtual string NetworkOperatorCode { get; set; } 

        /// <summary>The name of the carrier of the client's network connection. On Android:
        /// http://developer.android.com/reference/android/telephony/TelephonyManager.html#getNetworkOperatorName() On
        /// iOS: https://developer.apple.com/library/ios/documentation/NetworkingInternet/Reference/CTCarrier/Reference/
        /// Reference.html#//apple_ref/occ/instp/CTCarrier/carrierName</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("networkOperatorName")]
        public virtual string NetworkOperatorName { get; set; } 

        /// <summary>The amount of time in milliseconds it took for the client to establish a connection with the XMPP
        /// server.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("registrationLatencyMillis")]
        public virtual System.Nullable<int> RegistrationLatencyMillis { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for a result for a match participant.</summary>
    public class ParticipantResult : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#participantResult.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The ID of the participant.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("participantId")]
        public virtual string ParticipantId { get; set; } 

        /// <summary>The placement or ranking of the participant in the match results; a number from one to the number
        /// of participants in the match. Multiple participants may have the same placing value in case of a
        /// type.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("placing")]
        public virtual System.Nullable<int> Placing { get; set; } 

        /// <summary>The result of the participant for this match. Possible values are: - "MATCH_RESULT_WIN" - The
        /// participant won the match. - "MATCH_RESULT_LOSS" - The participant lost the match. - "MATCH_RESULT_TIE" -
        /// The participant tied the match. - "MATCH_RESULT_NONE" - There was no winner for the match (nobody wins or
        /// loses this kind of game.) - "MATCH_RESULT_DISCONNECT" - The participant disconnected / left during the
        /// match. - "MATCH_RESULT_DISAGREED" - Different clients reported different results for this
        /// participant.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("result")]
        public virtual string Result { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for peer channel diagnostics.</summary>
    public class PeerChannelDiagnostics : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>Number of bytes received.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("bytesReceived")]
        public virtual AggregateStats BytesReceived { get; set; } 

        /// <summary>Number of bytes sent.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("bytesSent")]
        public virtual AggregateStats BytesSent { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#peerChannelDiagnostics.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>Number of messages lost.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("numMessagesLost")]
        public virtual System.Nullable<int> NumMessagesLost { get; set; } 

        /// <summary>Number of messages received.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("numMessagesReceived")]
        public virtual System.Nullable<int> NumMessagesReceived { get; set; } 

        /// <summary>Number of messages sent.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("numMessagesSent")]
        public virtual System.Nullable<int> NumMessagesSent { get; set; } 

        /// <summary>Number of send failures.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("numSendFailures")]
        public virtual System.Nullable<int> NumSendFailures { get; set; } 

        /// <summary>Roundtrip latency stats in milliseconds.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("roundtripLatencyMillis")]
        public virtual AggregateStats RoundtripLatencyMillis { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for peer session diagnostics.</summary>
    public class PeerSessionDiagnostics : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>Connected time in milliseconds.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("connectedTimestampMillis")]
        public virtual System.Nullable<long> ConnectedTimestampMillis { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#peerSessionDiagnostics.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The participant ID of the peer.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("participantId")]
        public virtual string ParticipantId { get; set; } 

        /// <summary>Reliable channel diagnostics.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("reliableChannel")]
        public virtual PeerChannelDiagnostics ReliableChannel { get; set; } 

        /// <summary>Unreliable channel diagnostics.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("unreliableChannel")]
        public virtual PeerChannelDiagnostics UnreliableChannel { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for metadata about a player playing a game with the currently authenticated
    /// user.</summary>
    public class Played : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>True if the player was auto-matched with the currently authenticated user.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("autoMatched")]
        public virtual System.Nullable<bool> AutoMatched { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#played.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The last time the player played the game in milliseconds since the epoch in UTC.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("timeMillis")]
        public virtual System.Nullable<long> TimeMillis { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for a Player resource.</summary>
    public class Player : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The base URL for the image that represents the player.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("avatarImageUrl")]
        public virtual string AvatarImageUrl { get; set; } 

        /// <summary>The url to the landscape mode player banner image.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("bannerUrlLandscape")]
        public virtual string BannerUrlLandscape { get; set; } 

        /// <summary>The url to the portrait mode player banner image.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("bannerUrlPortrait")]
        public virtual string BannerUrlPortrait { get; set; } 

        /// <summary>The name to display for the player.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("displayName")]
        public virtual string DisplayName { get; set; } 

        /// <summary>An object to represent Play Game experience information for the player.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("experienceInfo")]
        public virtual PlayerExperienceInfo ExperienceInfo { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#player.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>Details about the last time this player played a multiplayer game with the currently authenticated
        /// player. Populated for PLAYED_WITH player collection members.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("lastPlayedWith")]
        public virtual Played LastPlayedWith { get; set; } 

        /// <summary>An object representation of the individual components of the player's name. For some players, these
        /// fields may not be present.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("name")]
        public virtual Player.NameData Name { get; set; } 

        /// <summary>The player ID that was used for this player the first time they signed into the game in question.
        /// This is only populated for calls to player.get for the requesting player, only if the player ID has
        /// subsequently changed, and only to clients that support remapping player IDs.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("originalPlayerId")]
        public virtual string OriginalPlayerId { get; set; } 

        /// <summary>The ID of the player.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("playerId")]
        public virtual string PlayerId { get; set; } 

        /// <summary>The player's profile settings. Controls whether or not the player's profile is visible to other
        /// players.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("profileSettings")]
        public virtual ProfileSettings ProfileSettings { get; set; } 

        /// <summary>The player's title rewarded for their game activities.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("title")]
        public virtual string Title { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
        

        /// <summary>An object representation of the individual components of the player's name. For some players, these
        /// fields may not be present.</summary>
        public class NameData
        {
            /// <summary>The family name of this player. In some places, this is known as the last name.</summary>
            [Newtonsoft.Json.JsonPropertyAttribute("familyName")]
            public virtual string FamilyName { get; set; } 

            /// <summary>The given name of this player. In some places, this is known as the first name.</summary>
            [Newtonsoft.Json.JsonPropertyAttribute("givenName")]
            public virtual string GivenName { get; set; } 

        }
    }    

    /// <summary>This is a JSON template for an achievement object.</summary>
    public class PlayerAchievement : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The state of the achievement. Possible values are: - "HIDDEN" - Achievement is hidden. - "REVEALED"
        /// - Achievement is revealed. - "UNLOCKED" - Achievement is unlocked.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("achievementState")]
        public virtual string AchievementState { get; set; } 

        /// <summary>The current steps for an incremental achievement.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("currentSteps")]
        public virtual System.Nullable<int> CurrentSteps { get; set; } 

        /// <summary>Experience points earned for the achievement. This field is absent for achievements that have not
        /// yet been unlocked and 0 for achievements that have been unlocked by testers but that are
        /// unpublished.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("experiencePoints")]
        public virtual System.Nullable<long> ExperiencePoints { get; set; } 

        /// <summary>The current steps for an incremental achievement as a string.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("formattedCurrentStepsString")]
        public virtual string FormattedCurrentStepsString { get; set; } 

        /// <summary>The ID of the achievement.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("id")]
        public virtual string Id { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#playerAchievement.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The timestamp of the last modification to this achievement's state.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("lastUpdatedTimestamp")]
        public virtual System.Nullable<long> LastUpdatedTimestamp { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for a list of achievement objects.</summary>
    public class PlayerAchievementListResponse : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The achievements.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("items")]
        public virtual System.Collections.Generic.IList<PlayerAchievement> Items { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#playerAchievementListResponse.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>Token corresponding to the next page of results.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("nextPageToken")]
        public virtual string NextPageToken { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for an event status resource.</summary>
    public class PlayerEvent : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The ID of the event definition.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("definitionId")]
        public virtual string DefinitionId { get; set; } 

        /// <summary>The current number of times this event has occurred, as a string. The formatting of this string
        /// depends on the configuration of your event in the Play Games Developer Console.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("formattedNumEvents")]
        public virtual string FormattedNumEvents { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#playerEvent.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The current number of times this event has occurred.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("numEvents")]
        public virtual System.Nullable<long> NumEvents { get; set; } 

        /// <summary>The ID of the player.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("playerId")]
        public virtual string PlayerId { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for a ListByPlayer response.</summary>
    public class PlayerEventListResponse : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The player events.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("items")]
        public virtual System.Collections.Generic.IList<PlayerEvent> Items { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#playerEventListResponse.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The pagination token for the next page of results.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("nextPageToken")]
        public virtual string NextPageToken { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for 1P/3P metadata about the player's experience.</summary>
    public class PlayerExperienceInfo : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The current number of experience points for the player.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("currentExperiencePoints")]
        public virtual System.Nullable<long> CurrentExperiencePoints { get; set; } 

        /// <summary>The current level of the player.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("currentLevel")]
        public virtual PlayerLevel CurrentLevel { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#playerExperienceInfo.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The timestamp when the player was leveled up, in millis since Unix epoch UTC.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("lastLevelUpTimestampMillis")]
        public virtual System.Nullable<long> LastLevelUpTimestampMillis { get; set; } 

        /// <summary>The next level of the player. If the current level is the maximum level, this should be same as the
        /// current level.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("nextLevel")]
        public virtual PlayerLevel NextLevel { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for a player leaderboard score object.</summary>
    public class PlayerLeaderboardScore : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#playerLeaderboardScore.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The ID of the leaderboard this score is in.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("leaderboard_id")]
        public virtual string LeaderboardId { get; set; } 

        /// <summary>The public rank of the score in this leaderboard. This object will not be present if the user is
        /// not sharing their scores publicly.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("publicRank")]
        public virtual LeaderboardScoreRank PublicRank { get; set; } 

        /// <summary>The formatted value of this score.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("scoreString")]
        public virtual string ScoreString { get; set; } 

        /// <summary>Additional information about the score. Values must contain no more than 64 URI-safe characters as
        /// defined by section 2.3 of RFC 3986.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("scoreTag")]
        public virtual string ScoreTag { get; set; } 

        /// <summary>The numerical value of this score.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("scoreValue")]
        public virtual System.Nullable<long> ScoreValue { get; set; } 

        /// <summary>The social rank of the score in this leaderboard.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("socialRank")]
        public virtual LeaderboardScoreRank SocialRank { get; set; } 

        /// <summary>The time span of this score. Possible values are: - "ALL_TIME" - The score is an all-time score. -
        /// "WEEKLY" - The score is a weekly score. - "DAILY" - The score is a daily score.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("timeSpan")]
        public virtual string TimeSpan { get; set; } 

        /// <summary>The timestamp at which this score was recorded, in milliseconds since the epoch in UTC.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("writeTimestamp")]
        public virtual System.Nullable<long> WriteTimestamp { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for a list of player leaderboard scores.</summary>
    public class PlayerLeaderboardScoreListResponse : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The leaderboard scores.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("items")]
        public virtual System.Collections.Generic.IList<PlayerLeaderboardScore> Items { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#playerLeaderboardScoreListResponse.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The pagination token for the next page of results.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("nextPageToken")]
        public virtual string NextPageToken { get; set; } 

        /// <summary>The Player resources for the owner of this score.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("player")]
        public virtual Player Player { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for 1P/3P metadata about a user's level.</summary>
    public class PlayerLevel : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#playerLevel.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The level for the user.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("level")]
        public virtual System.Nullable<int> Level { get; set; } 

        /// <summary>The maximum experience points for this level.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("maxExperiencePoints")]
        public virtual System.Nullable<long> MaxExperiencePoints { get; set; } 

        /// <summary>The minimum experience points for this level.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("minExperiencePoints")]
        public virtual System.Nullable<long> MinExperiencePoints { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for a third party player list response.</summary>
    public class PlayerListResponse : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The players.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("items")]
        public virtual System.Collections.Generic.IList<Player> Items { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#playerListResponse.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>Token corresponding to the next page of results.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("nextPageToken")]
        public virtual string NextPageToken { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for a player score.</summary>
    public class PlayerScore : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The formatted score for this player score.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("formattedScore")]
        public virtual string FormattedScore { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#playerScore.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The numerical value for this player score.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("score")]
        public virtual System.Nullable<long> Score { get; set; } 

        /// <summary>Additional information about this score. Values will contain no more than 64 URI-safe characters as
        /// defined by section 2.3 of RFC 3986.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("scoreTag")]
        public virtual string ScoreTag { get; set; } 

        /// <summary>The time span for this player score. Possible values are: - "ALL_TIME" - The score is an all-time
        /// score. - "WEEKLY" - The score is a weekly score. - "DAILY" - The score is a daily score.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("timeSpan")]
        public virtual string TimeSpan { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for a list of score submission statuses.</summary>
    public class PlayerScoreListResponse : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#playerScoreListResponse.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The score submissions statuses.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("submittedScores")]
        public virtual System.Collections.Generic.IList<PlayerScoreResponse> SubmittedScores { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for a list of leaderboard entry resources.</summary>
    public class PlayerScoreResponse : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The time spans where the submitted score is better than the existing score for that time span.
        /// Possible values are: - "ALL_TIME" - The score is an all-time score. - "WEEKLY" - The score is a weekly
        /// score. - "DAILY" - The score is a daily score.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("beatenScoreTimeSpans")]
        public virtual System.Collections.Generic.IList<string> BeatenScoreTimeSpans { get; set; } 

        /// <summary>The formatted value of the submitted score.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("formattedScore")]
        public virtual string FormattedScore { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#playerScoreResponse.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The leaderboard ID that this score was submitted to.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("leaderboardId")]
        public virtual string LeaderboardId { get; set; } 

        /// <summary>Additional information about this score. Values will contain no more than 64 URI-safe characters as
        /// defined by section 2.3 of RFC 3986.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("scoreTag")]
        public virtual string ScoreTag { get; set; } 

        /// <summary>The scores in time spans that have not been beaten. As an example, the submitted score may be
        /// better than the player's DAILY score, but not better than the player's scores for the WEEKLY or ALL_TIME
        /// time spans.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("unbeatenScores")]
        public virtual System.Collections.Generic.IList<PlayerScore> UnbeatenScores { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for a list of score submission requests</summary>
    public class PlayerScoreSubmissionList : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#playerScoreSubmissionList.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The score submissions.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("scores")]
        public virtual System.Collections.Generic.IList<ScoreSubmission> Scores { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for profile settings</summary>
    public class ProfileSettings : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#profileSettings.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The player's current profile visibility. This field is visible to both 1P and 3P APIs.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("profileVisible")]
        public virtual System.Nullable<bool> ProfileVisible { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for a push token resource.</summary>
    public class PushToken : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The revision of the client SDK used by your application, in the same format that's used by
        /// revisions.check. Used to send backward compatible messages. Format: [PLATFORM_TYPE]:[VERSION_NUMBER].
        /// Possible values of PLATFORM_TYPE are: - IOS - Push token is for iOS</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("clientRevision")]
        public virtual string ClientRevision { get; set; } 

        /// <summary>Unique identifier for this push token.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("id")]
        public virtual PushTokenId Id { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#pushToken.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The preferred language for notifications that are sent using this token.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("language")]
        public virtual string Language { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for a push token ID resource.</summary>
    public class PushTokenId : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>A push token ID for iOS devices.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("ios")]
        public virtual PushTokenId.IosData Ios { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#pushTokenId.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
        

        /// <summary>A push token ID for iOS devices.</summary>
        public class IosData
        {
            /// <summary>Device token supplied by an iOS system call to register for remote notifications. Encode this
            /// field as web-safe base64.</summary>
            [Newtonsoft.Json.JsonPropertyAttribute("apns_device_token")]
            public virtual string ApnsDeviceToken { get; set; } 

            /// <summary>Indicates whether this token should be used for the production or sandbox APNS
            /// server.</summary>
            [Newtonsoft.Json.JsonPropertyAttribute("apns_environment")]
            public virtual string ApnsEnvironment { get; set; } 

        }
    }    

    /// <summary>This is a JSON template for a Quest resource.</summary>
    public class Quest : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The timestamp at which the user accepted the quest in milliseconds since the epoch in UTC. Only
        /// present if the player has accepted the quest.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("acceptedTimestampMillis")]
        public virtual System.Nullable<long> AcceptedTimestampMillis { get; set; } 

        /// <summary>The ID of the application this quest is part of.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("applicationId")]
        public virtual string ApplicationId { get; set; } 

        /// <summary>The banner image URL for the quest.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("bannerUrl")]
        public virtual string BannerUrl { get; set; } 

        /// <summary>The description of the quest.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("description")]
        public virtual string Description { get; set; } 

        /// <summary>The timestamp at which the quest ceases to be active in milliseconds since the epoch in
        /// UTC.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("endTimestampMillis")]
        public virtual System.Nullable<long> EndTimestampMillis { get; set; } 

        /// <summary>The icon image URL for the quest.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("iconUrl")]
        public virtual string IconUrl { get; set; } 

        /// <summary>The ID of the quest.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("id")]
        public virtual string Id { get; set; } 

        /// <summary>Indicates whether the banner image being returned is a default image, or is game-
        /// provided.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("isDefaultBannerUrl")]
        public virtual System.Nullable<bool> IsDefaultBannerUrl { get; set; } 

        /// <summary>Indicates whether the icon image being returned is a default image, or is game-provided.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("isDefaultIconUrl")]
        public virtual System.Nullable<bool> IsDefaultIconUrl { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#quest.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The timestamp at which the quest was last updated by the user in milliseconds since the epoch in
        /// UTC. Only present if the player has accepted the quest.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("lastUpdatedTimestampMillis")]
        public virtual System.Nullable<long> LastUpdatedTimestampMillis { get; set; } 

        /// <summary>The quest milestones.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("milestones")]
        public virtual System.Collections.Generic.IList<QuestMilestone> Milestones { get; set; } 

        /// <summary>The name of the quest.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("name")]
        public virtual string Name { get; set; } 

        /// <summary>The timestamp at which the user should be notified that the quest will end soon in milliseconds
        /// since the epoch in UTC.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("notifyTimestampMillis")]
        public virtual System.Nullable<long> NotifyTimestampMillis { get; set; } 

        /// <summary>The timestamp at which the quest becomes active in milliseconds since the epoch in UTC.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("startTimestampMillis")]
        public virtual System.Nullable<long> StartTimestampMillis { get; set; } 

        /// <summary>The state of the quest. Possible values are: - "UPCOMING": The quest is upcoming. The user can see
        /// the quest, but cannot accept it until it is open. - "OPEN": The quest is currently open and may be accepted
        /// at this time. - "ACCEPTED": The user is currently participating in this quest. - "COMPLETED": The user has
        /// completed the quest. - "FAILED": The quest was attempted but was not completed before the deadline expired.
        /// - "EXPIRED": The quest has expired and was not accepted. - "DELETED": The quest should be deleted from the
        /// local database.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("state")]
        public virtual string State { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for a Quest Criterion Contribution resource.</summary>
    public class QuestContribution : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The formatted value of the contribution as a string. Format depends on the configuration for the
        /// associated event definition in the Play Games Developer Console.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("formattedValue")]
        public virtual string FormattedValue { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#questContribution.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The value of the contribution.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("value")]
        public virtual System.Nullable<long> Value { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for a Quest Criterion resource.</summary>
    public class QuestCriterion : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The total number of times the associated event must be incremented for the player to complete this
        /// quest.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("completionContribution")]
        public virtual QuestContribution CompletionContribution { get; set; } 

        /// <summary>The number of increments the player has made toward the completion count event increments required
        /// to complete the quest. This value will not exceed the completion contribution. There will be no
        /// currentContribution until the player has accepted the quest.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("currentContribution")]
        public virtual QuestContribution CurrentContribution { get; set; } 

        /// <summary>The ID of the event the criterion corresponds to.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("eventId")]
        public virtual string EventId { get; set; } 

        /// <summary>The value of the event associated with this quest at the time that the quest was accepted. This
        /// value may change if event increments that took place before the start of quest are uploaded after the quest
        /// starts. There will be no initialPlayerProgress until the player has accepted the quest.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("initialPlayerProgress")]
        public virtual QuestContribution InitialPlayerProgress { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#questCriterion.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for a list of quest objects.</summary>
    public class QuestListResponse : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The quests.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("items")]
        public virtual System.Collections.Generic.IList<Quest> Items { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#questListResponse.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>Token corresponding to the next page of results.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("nextPageToken")]
        public virtual string NextPageToken { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for a Quest Milestone resource.</summary>
    public class QuestMilestone : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The completion reward data of the milestone, represented as a Base64-encoded string. This is a
        /// developer-specified binary blob with size between 0 and 2 KB before encoding.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("completionRewardData")]
        public virtual string CompletionRewardData { get; set; } 

        /// <summary>The criteria of the milestone.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("criteria")]
        public virtual System.Collections.Generic.IList<QuestCriterion> Criteria { get; set; } 

        /// <summary>The milestone ID.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("id")]
        public virtual string Id { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#questMilestone.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The current state of the milestone. Possible values are: - "COMPLETED_NOT_CLAIMED" - The milestone
        /// is complete, but has not yet been claimed. - "CLAIMED" - The milestone is complete and has been claimed. -
        /// "NOT_COMPLETED" - The milestone has not yet been completed. - "NOT_STARTED" - The milestone is for a quest
        /// that has not yet been accepted.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("state")]
        public virtual string State { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for the result of checking a revision.</summary>
    public class RevisionCheckResponse : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The version of the API this client revision should use when calling API methods.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("apiVersion")]
        public virtual string ApiVersion { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#revisionCheckResponse.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The result of the revision check. Possible values are: - "OK" - The revision being used is current.
        /// - "DEPRECATED" - There is currently a newer version available, but the revision being used still works. -
        /// "INVALID" - The revision being used is not supported in any released version.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("revisionStatus")]
        public virtual string RevisionStatus { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for a room resource object.</summary>
    public class Room : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The ID of the application being played.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("applicationId")]
        public virtual string ApplicationId { get; set; } 

        /// <summary>Criteria for auto-matching players into this room.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("autoMatchingCriteria")]
        public virtual RoomAutoMatchingCriteria AutoMatchingCriteria { get; set; } 

        /// <summary>Auto-matching status for this room. Not set if the room is not currently in the auto-matching
        /// queue.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("autoMatchingStatus")]
        public virtual RoomAutoMatchStatus AutoMatchingStatus { get; set; } 

        /// <summary>Details about the room creation.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("creationDetails")]
        public virtual RoomModification CreationDetails { get; set; } 

        /// <summary>This short description is generated by our servers and worded relative to the player requesting the
        /// room. It is intended to be displayed when the room is shown in a list (that is, an invitation to a
        /// room.)</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("description")]
        public virtual string Description { get; set; } 

        /// <summary>The ID of the participant that invited the user to the room. Not set if the user was not invited to
        /// the room.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("inviterId")]
        public virtual string InviterId { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#room.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>Details about the last update to the room.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("lastUpdateDetails")]
        public virtual RoomModification LastUpdateDetails { get; set; } 

        /// <summary>The participants involved in the room, along with their statuses. Includes participants who have
        /// left or declined invitations.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("participants")]
        public virtual System.Collections.Generic.IList<RoomParticipant> Participants { get; set; } 

        /// <summary>Globally unique ID for a room.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("roomId")]
        public virtual string RoomId { get; set; } 

        /// <summary>The version of the room status: an increasing counter, used by the client to ignore out-of-order
        /// updates to room status.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("roomStatusVersion")]
        public virtual System.Nullable<int> RoomStatusVersion { get; set; } 

        /// <summary>The status of the room. Possible values are: - "ROOM_INVITING" - One or more players have been
        /// invited and not responded. - "ROOM_AUTO_MATCHING" - One or more slots need to be filled by auto-matching. -
        /// "ROOM_CONNECTING" - Players have joined and are connecting to each other (either before or after auto-
        /// matching). - "ROOM_ACTIVE" - All players have joined and connected to each other. - "ROOM_DELETED" - The
        /// room should no longer be shown on the client. Returned in sync calls when a player joins a room (as a
        /// tombstone), or for rooms where all joined participants have left.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("status")]
        public virtual string Status { get; set; } 

        /// <summary>The variant / mode of the application being played; can be any integer value, or left
        /// blank.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("variant")]
        public virtual System.Nullable<int> Variant { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for status of room automatching that is in progress.</summary>
    public class RoomAutoMatchStatus : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#roomAutoMatchStatus.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>An estimate for the amount of time (in seconds) that auto-matching is expected to take to
        /// complete.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("waitEstimateSeconds")]
        public virtual System.Nullable<int> WaitEstimateSeconds { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for a room auto-match criteria object.</summary>
    public class RoomAutoMatchingCriteria : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>A bitmask indicating when auto-matches are valid. When ANDed with other exclusive bitmasks, the
        /// result must be zero. Can be used to support exclusive roles within a game.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("exclusiveBitmask")]
        public virtual System.Nullable<long> ExclusiveBitmask { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#roomAutoMatchingCriteria.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The maximum number of players that should be added to the room by auto-matching.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("maxAutoMatchingPlayers")]
        public virtual System.Nullable<int> MaxAutoMatchingPlayers { get; set; } 

        /// <summary>The minimum number of players that should be added to the room by auto-matching.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("minAutoMatchingPlayers")]
        public virtual System.Nullable<int> MinAutoMatchingPlayers { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for the client address when setting up a room.</summary>
    public class RoomClientAddress : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#roomClientAddress.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The XMPP address of the client on the Google Games XMPP network.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("xmppAddress")]
        public virtual string XmppAddress { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for a room creation request.</summary>
    public class RoomCreateRequest : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>Criteria for auto-matching players into this room.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("autoMatchingCriteria")]
        public virtual RoomAutoMatchingCriteria AutoMatchingCriteria { get; set; } 

        /// <summary>The capabilities that this client supports for realtime communication.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("capabilities")]
        public virtual System.Collections.Generic.IList<string> Capabilities { get; set; } 

        /// <summary>Client address for the player creating the room.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("clientAddress")]
        public virtual RoomClientAddress ClientAddress { get; set; } 

        /// <summary>The player IDs to invite to the room.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("invitedPlayerIds")]
        public virtual System.Collections.Generic.IList<string> InvitedPlayerIds { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#roomCreateRequest.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>Network diagnostics for the client creating the room.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("networkDiagnostics")]
        public virtual NetworkDiagnostics NetworkDiagnostics { get; set; } 

        /// <summary>A randomly generated numeric ID. This number is used at the server to ensure that the request is
        /// handled correctly across retries.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("requestId")]
        public virtual System.Nullable<long> RequestId { get; set; } 

        /// <summary>The variant / mode of the application to be played. This can be any integer value, or left blank.
        /// You should use a small number of variants to keep the auto-matching pool as large as possible.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("variant")]
        public virtual System.Nullable<int> Variant { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for a join room request.</summary>
    public class RoomJoinRequest : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The capabilities that this client supports for realtime communication.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("capabilities")]
        public virtual System.Collections.Generic.IList<string> Capabilities { get; set; } 

        /// <summary>Client address for the player joining the room.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("clientAddress")]
        public virtual RoomClientAddress ClientAddress { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#roomJoinRequest.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>Network diagnostics for the client joining the room.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("networkDiagnostics")]
        public virtual NetworkDiagnostics NetworkDiagnostics { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for room leave diagnostics.</summary>
    public class RoomLeaveDiagnostics : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>Android network subtype.
        /// http://developer.android.com/reference/android/net/NetworkInfo.html#getSubtype()</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("androidNetworkSubtype")]
        public virtual System.Nullable<int> AndroidNetworkSubtype { get; set; } 

        /// <summary>Android network type.
        /// http://developer.android.com/reference/android/net/NetworkInfo.html#getType()</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("androidNetworkType")]
        public virtual System.Nullable<int> AndroidNetworkType { get; set; } 

        /// <summary>iOS network type as defined in Reachability.h.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("iosNetworkType")]
        public virtual System.Nullable<int> IosNetworkType { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#roomLeaveDiagnostics.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The MCC+MNC code for the client's network connection. On Android:
        /// http://developer.android.com/reference/android/telephony/TelephonyManager.html#getNetworkOperator() On iOS,
        /// see: https://developer.apple.com/library/ios/documentation/NetworkingInternet/Reference/CTCarrier/Reference/
        /// Reference.html</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("networkOperatorCode")]
        public virtual string NetworkOperatorCode { get; set; } 

        /// <summary>The name of the carrier of the client's network connection. On Android:
        /// http://developer.android.com/reference/android/telephony/TelephonyManager.html#getNetworkOperatorName() On
        /// iOS: https://developer.apple.com/library/ios/documentation/NetworkingInternet/Reference/CTCarrier/Reference/
        /// Reference.html#//apple_ref/occ/instp/CTCarrier/carrierName</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("networkOperatorName")]
        public virtual string NetworkOperatorName { get; set; } 

        /// <summary>Diagnostics about all peer sessions.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("peerSession")]
        public virtual System.Collections.Generic.IList<PeerSessionDiagnostics> PeerSession { get; set; } 

        /// <summary>Whether or not sockets were used.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("socketsUsed")]
        public virtual System.Nullable<bool> SocketsUsed { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for a leave room request.</summary>
    public class RoomLeaveRequest : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#roomLeaveRequest.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>Diagnostics for a player leaving the room.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("leaveDiagnostics")]
        public virtual RoomLeaveDiagnostics LeaveDiagnostics { get; set; } 

        /// <summary>Reason for leaving the match. Possible values are: - "PLAYER_LEFT" - The player chose to leave the
        /// room.. - "GAME_LEFT" - The game chose to remove the player from the room. - "REALTIME_ABANDONED" - The
        /// player switched to another application and abandoned the room. - "REALTIME_PEER_CONNECTION_FAILURE" - The
        /// client was unable to establish a connection to other peer(s). - "REALTIME_SERVER_CONNECTION_FAILURE" - The
        /// client was unable to communicate with the server. - "REALTIME_SERVER_ERROR" - The client received an error
        /// response when it tried to communicate with the server. - "REALTIME_TIMEOUT" - The client timed out while
        /// waiting for a room. - "REALTIME_CLIENT_DISCONNECTING" - The client disconnects without first calling Leave.
        /// - "REALTIME_SIGN_OUT" - The user signed out of G+ while in the room. - "REALTIME_GAME_CRASHED" - The game
        /// crashed. - "REALTIME_ROOM_SERVICE_CRASHED" - RoomAndroidService crashed. -
        /// "REALTIME_DIFFERENT_CLIENT_ROOM_OPERATION" - Another client is trying to enter a room. -
        /// "REALTIME_SAME_CLIENT_ROOM_OPERATION" - The same client is trying to enter a new room.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("reason")]
        public virtual string Reason { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for a list of rooms.</summary>
    public class RoomList : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The rooms.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("items")]
        public virtual System.Collections.Generic.IList<Room> Items { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#roomList.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The pagination token for the next page of results.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("nextPageToken")]
        public virtual string NextPageToken { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for room modification metadata.</summary>
    public class RoomModification : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#roomModification.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The timestamp at which they modified the room, in milliseconds since the epoch in UTC.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("modifiedTimestampMillis")]
        public virtual System.Nullable<long> ModifiedTimestampMillis { get; set; } 

        /// <summary>The ID of the participant that modified the room.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("participantId")]
        public virtual string ParticipantId { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for an update on the status of a peer in a room.</summary>
    public class RoomP2PStatus : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The amount of time in milliseconds it took to establish connections with this peer.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("connectionSetupLatencyMillis")]
        public virtual System.Nullable<int> ConnectionSetupLatencyMillis { get; set; } 

        /// <summary>The error code in event of a failure. Possible values are: - "P2P_FAILED" - The client failed to
        /// establish a P2P connection with the peer. - "PRESENCE_FAILED" - The client failed to register to receive P2P
        /// connections. - "RELAY_SERVER_FAILED" - The client received an error when trying to use the relay server to
        /// establish a P2P connection with the peer.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("error")]
        public virtual string Error { get; set; } 

        /// <summary>More detailed diagnostic message returned in event of a failure.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("error_reason")]
        public virtual string ErrorReason { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#roomP2PStatus.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The ID of the participant.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("participantId")]
        public virtual string ParticipantId { get; set; } 

        /// <summary>The status of the peer in the room. Possible values are: - "CONNECTION_ESTABLISHED" - The client
        /// established a P2P connection with the peer. - "CONNECTION_FAILED" - The client failed to establish directed
        /// presence with the peer.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("status")]
        public virtual string Status { get; set; } 

        /// <summary>The amount of time in milliseconds it took to send packets back and forth on the unreliable channel
        /// with this peer.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("unreliableRoundtripLatencyMillis")]
        public virtual System.Nullable<int> UnreliableRoundtripLatencyMillis { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for an update on the status of peers in a room.</summary>
    public class RoomP2PStatuses : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#roomP2PStatuses.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The updates for the peers.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("updates")]
        public virtual System.Collections.Generic.IList<RoomP2PStatus> Updates { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for a participant in a room.</summary>
    public class RoomParticipant : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>True if this participant was auto-matched with the requesting player.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("autoMatched")]
        public virtual System.Nullable<bool> AutoMatched { get; set; } 

        /// <summary>Information about a player that has been anonymously auto-matched against the requesting player.
        /// (Either player or autoMatchedPlayer will be set.)</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("autoMatchedPlayer")]
        public virtual AnonymousPlayer AutoMatchedPlayer { get; set; } 

        /// <summary>The capabilities which can be used when communicating with this participant.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("capabilities")]
        public virtual System.Collections.Generic.IList<string> Capabilities { get; set; } 

        /// <summary>Client address for the participant.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("clientAddress")]
        public virtual RoomClientAddress ClientAddress { get; set; } 

        /// <summary>True if this participant is in the fully connected set of peers in the room.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("connected")]
        public virtual System.Nullable<bool> Connected { get; set; } 

        /// <summary>An identifier for the participant in the scope of the room. Cannot be used to identify a player
        /// across rooms or in other contexts.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("id")]
        public virtual string Id { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#roomParticipant.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The reason the participant left the room; populated if the participant status is PARTICIPANT_LEFT.
        /// Possible values are: - "PLAYER_LEFT" - The player explicitly chose to leave the room. - "GAME_LEFT" - The
        /// game chose to remove the player from the room. - "ABANDONED" - The player switched to another application
        /// and abandoned the room. - "PEER_CONNECTION_FAILURE" - The client was unable to establish or maintain a
        /// connection to other peer(s) in the room. - "SERVER_ERROR" - The client received an error response when it
        /// tried to communicate with the server. - "TIMEOUT" - The client timed out while waiting for players to join
        /// and connect. - "PRESENCE_FAILURE" - The client's XMPP connection ended abruptly.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("leaveReason")]
        public virtual string LeaveReason { get; set; } 

        /// <summary>Information about the player. Not populated if this player was anonymously auto-matched against the
        /// requesting player. (Either player or autoMatchedPlayer will be set.)</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("player")]
        public virtual Player Player { get; set; } 

        /// <summary>The status of the participant with respect to the room. Possible values are: -
        /// "PARTICIPANT_INVITED" - The participant has been invited to join the room, but has not yet responded. -
        /// "PARTICIPANT_JOINED" - The participant has joined the room (either after creating it or accepting an
        /// invitation.) - "PARTICIPANT_DECLINED" - The participant declined an invitation to join the room. -
        /// "PARTICIPANT_LEFT" - The participant joined the room and then left it.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("status")]
        public virtual string Status { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for the status of a room that the player has joined.</summary>
    public class RoomStatus : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>Auto-matching status for this room. Not set if the room is not currently in the automatching
        /// queue.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("autoMatchingStatus")]
        public virtual RoomAutoMatchStatus AutoMatchingStatus { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#roomStatus.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The participants involved in the room, along with their statuses. Includes participants who have
        /// left or declined invitations.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("participants")]
        public virtual System.Collections.Generic.IList<RoomParticipant> Participants { get; set; } 

        /// <summary>Globally unique ID for a room.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("roomId")]
        public virtual string RoomId { get; set; } 

        /// <summary>The status of the room. Possible values are: - "ROOM_INVITING" - One or more players have been
        /// invited and not responded. - "ROOM_AUTO_MATCHING" - One or more slots need to be filled by auto-matching. -
        /// "ROOM_CONNECTING" - Players have joined are connecting to each other (either before or after auto-matching).
        /// - "ROOM_ACTIVE" - All players have joined and connected to each other. - "ROOM_DELETED" - All joined players
        /// have left.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("status")]
        public virtual string Status { get; set; } 

        /// <summary>The version of the status for the room: an increasing counter, used by the client to ignore out-of-
        /// order updates to room status.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("statusVersion")]
        public virtual System.Nullable<int> StatusVersion { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for a request to submit a score to leaderboards.</summary>
    public class ScoreSubmission : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#scoreSubmission.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The leaderboard this score is being submitted to.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("leaderboardId")]
        public virtual string LeaderboardId { get; set; } 

        /// <summary>The new score being submitted.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("score")]
        public virtual System.Nullable<long> Score { get; set; } 

        /// <summary>Additional information about this score. Values will contain no more than 64 URI-safe characters as
        /// defined by section 2.3 of RFC 3986.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("scoreTag")]
        public virtual string ScoreTag { get; set; } 

        /// <summary>Signature Values will contain URI-safe characters as defined by section 2.3 of RFC 3986.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("signature")]
        public virtual string Signature { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for an snapshot object.</summary>
    public class Snapshot : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The cover image of this snapshot. May be absent if there is no image.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("coverImage")]
        public virtual SnapshotImage CoverImage { get; set; } 

        /// <summary>The description of this snapshot.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("description")]
        public virtual string Description { get; set; } 

        /// <summary>The ID of the file underlying this snapshot in the Drive API. Only present if the snapshot is a
        /// view on a Drive file and the file is owned by the caller.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("driveId")]
        public virtual string DriveId { get; set; } 

        /// <summary>The duration associated with this snapshot, in millis.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("durationMillis")]
        public virtual System.Nullable<long> DurationMillis { get; set; } 

        /// <summary>The ID of the snapshot.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("id")]
        public virtual string Id { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#snapshot.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The timestamp (in millis since Unix epoch) of the last modification to this snapshot.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("lastModifiedMillis")]
        public virtual System.Nullable<long> LastModifiedMillis { get; set; } 

        /// <summary>The progress value (64-bit integer set by developer) associated with this snapshot.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("progressValue")]
        public virtual System.Nullable<long> ProgressValue { get; set; } 

        /// <summary>The title of this snapshot.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("title")]
        public virtual string Title { get; set; } 

        /// <summary>The type of this snapshot. Possible values are: - "SAVE_GAME" - A snapshot representing a save
        /// game.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("type")]
        public virtual string Type { get; set; } 

        /// <summary>The unique name provided when the snapshot was created.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("uniqueName")]
        public virtual string UniqueName { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for an image of a snapshot.</summary>
    public class SnapshotImage : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The height of the image.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("height")]
        public virtual System.Nullable<int> Height { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#snapshotImage.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The MIME type of the image.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("mime_type")]
        public virtual string MimeType { get; set; } 

        /// <summary>The URL of the image. This URL may be invalidated at any time and should not be cached.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("url")]
        public virtual string Url { get; set; } 

        /// <summary>The width of the image.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("width")]
        public virtual System.Nullable<int> Width { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for a list of snapshot objects.</summary>
    public class SnapshotListResponse : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The snapshots.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("items")]
        public virtual System.Collections.Generic.IList<Snapshot> Items { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#snapshotListResponse.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>Token corresponding to the next page of results. If there are no more results, the token is
        /// omitted.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("nextPageToken")]
        public virtual string NextPageToken { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for an turn-based auto-match criteria object.</summary>
    public class TurnBasedAutoMatchingCriteria : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>A bitmask indicating when auto-matches are valid. When ANDed with other exclusive bitmasks, the
        /// result must be zero. Can be used to support exclusive roles within a game.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("exclusiveBitmask")]
        public virtual System.Nullable<long> ExclusiveBitmask { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#turnBasedAutoMatchingCriteria.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The maximum number of players that should be added to the match by auto-matching.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("maxAutoMatchingPlayers")]
        public virtual System.Nullable<int> MaxAutoMatchingPlayers { get; set; } 

        /// <summary>The minimum number of players that should be added to the match by auto-matching.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("minAutoMatchingPlayers")]
        public virtual System.Nullable<int> MinAutoMatchingPlayers { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for a turn-based match resource object.</summary>
    public class TurnBasedMatch : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The ID of the application being played.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("applicationId")]
        public virtual string ApplicationId { get; set; } 

        /// <summary>Criteria for auto-matching players into this match.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("autoMatchingCriteria")]
        public virtual TurnBasedAutoMatchingCriteria AutoMatchingCriteria { get; set; } 

        /// <summary>Details about the match creation.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("creationDetails")]
        public virtual TurnBasedMatchModification CreationDetails { get; set; } 

        /// <summary>The data / game state for this match.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("data")]
        public virtual TurnBasedMatchData Data { get; set; } 

        /// <summary>This short description is generated by our servers based on turn state and is localized and worded
        /// relative to the player requesting the match. It is intended to be displayed when the match is shown in a
        /// list.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("description")]
        public virtual string Description { get; set; } 

        /// <summary>The ID of the participant that invited the user to the match. Not set if the user was not invited
        /// to the match.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("inviterId")]
        public virtual string InviterId { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#turnBasedMatch.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>Details about the last update to the match.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("lastUpdateDetails")]
        public virtual TurnBasedMatchModification LastUpdateDetails { get; set; } 

        /// <summary>Globally unique ID for a turn-based match.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("matchId")]
        public virtual string MatchId { get; set; } 

        /// <summary>The number of the match in a chain of rematches. Will be set to 1 for the first match and
        /// incremented by 1 for each rematch.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("matchNumber")]
        public virtual System.Nullable<int> MatchNumber { get; set; } 

        /// <summary>The version of this match: an increasing counter, used to avoid out-of-date updates to the
        /// match.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("matchVersion")]
        public virtual System.Nullable<int> MatchVersion { get; set; } 

        /// <summary>The participants involved in the match, along with their statuses. Includes participants who have
        /// left or declined invitations.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("participants")]
        public virtual System.Collections.Generic.IList<TurnBasedMatchParticipant> Participants { get; set; } 

        /// <summary>The ID of the participant that is taking a turn.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("pendingParticipantId")]
        public virtual string PendingParticipantId { get; set; } 

        /// <summary>The data / game state for the previous match; set for the first turn of rematches only.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("previousMatchData")]
        public virtual TurnBasedMatchData PreviousMatchData { get; set; } 

        /// <summary>The ID of a rematch of this match. Only set for completed matches that have been
        /// rematched.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("rematchId")]
        public virtual string RematchId { get; set; } 

        /// <summary>The results reported for this match.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("results")]
        public virtual System.Collections.Generic.IList<ParticipantResult> Results { get; set; } 

        /// <summary>The status of the match. Possible values are: - "MATCH_AUTO_MATCHING" - One or more slots need to
        /// be filled by auto-matching; the match cannot be established until they are filled. - "MATCH_ACTIVE" - The
        /// match has started. - "MATCH_COMPLETE" - The match has finished. - "MATCH_CANCELED" - The match was canceled.
        /// - "MATCH_EXPIRED" - The match expired due to inactivity. - "MATCH_DELETED" - The match should no longer be
        /// shown on the client. Returned only for tombstones for matches when sync is called.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("status")]
        public virtual string Status { get; set; } 

        /// <summary>The status of the current user in the match. Derived from the match type, match status, the user's
        /// participant status, and the pending participant for the match. Possible values are: - "USER_INVITED" - The
        /// user has been invited to join the match and has not responded yet. - "USER_AWAITING_TURN" - The user is
        /// waiting for their turn. - "USER_TURN" - The user has an action to take in the match. -
        /// "USER_MATCH_COMPLETED" - The match has ended (it is completed, canceled, or expired.)</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("userMatchStatus")]
        public virtual string UserMatchStatus { get; set; } 

        /// <summary>The variant / mode of the application being played; can be any integer value, or left
        /// blank.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("variant")]
        public virtual System.Nullable<int> Variant { get; set; } 

        /// <summary>The ID of another participant in the match that can be used when describing the participants the
        /// user is playing with.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("withParticipantId")]
        public virtual string WithParticipantId { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for a turn-based match creation request.</summary>
    public class TurnBasedMatchCreateRequest : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>Criteria for auto-matching players into this match.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("autoMatchingCriteria")]
        public virtual TurnBasedAutoMatchingCriteria AutoMatchingCriteria { get; set; } 

        /// <summary>The player ids to invite to the match.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("invitedPlayerIds")]
        public virtual System.Collections.Generic.IList<string> InvitedPlayerIds { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#turnBasedMatchCreateRequest.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>A randomly generated numeric ID. This number is used at the server to ensure that the request is
        /// handled correctly across retries.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("requestId")]
        public virtual System.Nullable<long> RequestId { get; set; } 

        /// <summary>The variant / mode of the application to be played. This can be any integer value, or left blank.
        /// You should use a small number of variants to keep the auto-matching pool as large as possible.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("variant")]
        public virtual System.Nullable<int> Variant { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for a turn-based match data object.</summary>
    public class TurnBasedMatchData : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The byte representation of the data (limited to 128 kB), as a Base64-encoded string with the
        /// URL_SAFE encoding option.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("data")]
        public virtual string Data { get; set; } 

        /// <summary>True if this match has data available but it wasn't returned in a list response; fetching the match
        /// individually will retrieve this data.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("dataAvailable")]
        public virtual System.Nullable<bool> DataAvailable { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#turnBasedMatchData.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for sending a turn-based match data object.</summary>
    public class TurnBasedMatchDataRequest : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The byte representation of the data (limited to 128 kB), as a Base64-encoded string with the
        /// URL_SAFE encoding option.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("data")]
        public virtual string Data { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#turnBasedMatchDataRequest.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for a list of turn-based matches.</summary>
    public class TurnBasedMatchList : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The matches.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("items")]
        public virtual System.Collections.Generic.IList<TurnBasedMatch> Items { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#turnBasedMatchList.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The pagination token for the next page of results.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("nextPageToken")]
        public virtual string NextPageToken { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for turn-based match modification metadata.</summary>
    public class TurnBasedMatchModification : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#turnBasedMatchModification.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The timestamp at which they modified the match, in milliseconds since the epoch in UTC.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("modifiedTimestampMillis")]
        public virtual System.Nullable<long> ModifiedTimestampMillis { get; set; } 

        /// <summary>The ID of the participant that modified the match.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("participantId")]
        public virtual string ParticipantId { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for a participant in a turn-based match.</summary>
    public class TurnBasedMatchParticipant : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>True if this participant was auto-matched with the requesting player.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("autoMatched")]
        public virtual System.Nullable<bool> AutoMatched { get; set; } 

        /// <summary>Information about a player that has been anonymously auto-matched against the requesting player.
        /// (Either player or autoMatchedPlayer will be set.)</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("autoMatchedPlayer")]
        public virtual AnonymousPlayer AutoMatchedPlayer { get; set; } 

        /// <summary>An identifier for the participant in the scope of the match. Cannot be used to identify a player
        /// across matches or in other contexts.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("id")]
        public virtual string Id { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#turnBasedMatchParticipant.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>Information about the player. Not populated if this player was anonymously auto-matched against the
        /// requesting player. (Either player or autoMatchedPlayer will be set.)</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("player")]
        public virtual Player Player { get; set; } 

        /// <summary>The status of the participant with respect to the match. Possible values are: -
        /// "PARTICIPANT_NOT_INVITED_YET" - The participant is slated to be invited to the match, but the invitation has
        /// not been sent; the invite will be sent when it becomes their turn. - "PARTICIPANT_INVITED" - The participant
        /// has been invited to join the match, but has not yet responded. - "PARTICIPANT_JOINED" - The participant has
        /// joined the match (either after creating it or accepting an invitation.) - "PARTICIPANT_DECLINED" - The
        /// participant declined an invitation to join the match. - "PARTICIPANT_LEFT" - The participant joined the
        /// match and then left it. - "PARTICIPANT_FINISHED" - The participant finished playing in the match. -
        /// "PARTICIPANT_UNRESPONSIVE" - The participant did not take their turn in the allotted time.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("status")]
        public virtual string Status { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for a rematch response.</summary>
    public class TurnBasedMatchRematch : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#turnBasedMatchRematch.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The old match that the rematch was created from; will be updated such that the rematchId field will
        /// point at the new match.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("previousMatch")]
        public virtual TurnBasedMatch PreviousMatch { get; set; } 

        /// <summary>The newly created match; a rematch of the old match with the same participants.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("rematch")]
        public virtual TurnBasedMatch Rematch { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for a turn-based match results object.</summary>
    public class TurnBasedMatchResults : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The final match data.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("data")]
        public virtual TurnBasedMatchDataRequest Data { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#turnBasedMatchResults.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The version of the match being updated.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("matchVersion")]
        public virtual System.Nullable<int> MatchVersion { get; set; } 

        /// <summary>The match results for the participants in the match.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("results")]
        public virtual System.Collections.Generic.IList<ParticipantResult> Results { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for a list of turn-based matches returned from a sync.</summary>
    public class TurnBasedMatchSync : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The matches.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("items")]
        public virtual System.Collections.Generic.IList<TurnBasedMatch> Items { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#turnBasedMatchSync.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>True if there were more matches available to fetch at the time the response was generated (which
        /// were not returned due to page size limits.)</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("moreAvailable")]
        public virtual System.Nullable<bool> MoreAvailable { get; set; } 

        /// <summary>The pagination token for the next page of results.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("nextPageToken")]
        public virtual string NextPageToken { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }    

    /// <summary>This is a JSON template for the object representing a turn.</summary>
    public class TurnBasedMatchTurn : Google.Apis.Requests.IDirectResponseSchema
    {
        /// <summary>The shared game state data after the turn is over.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("data")]
        public virtual TurnBasedMatchDataRequest Data { get; set; } 

        /// <summary>Uniquely identifies the type of this resource. Value is always the fixed string
        /// games#turnBasedMatchTurn.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("kind")]
        public virtual string Kind { get; set; } 

        /// <summary>The version of this match: an increasing counter, used to avoid out-of-date updates to the
        /// match.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("matchVersion")]
        public virtual System.Nullable<int> MatchVersion { get; set; } 

        /// <summary>The ID of the participant who should take their turn next. May be set to the current player's
        /// participant ID to update match state without changing the turn. If not set, the match will wait for other
        /// player(s) to join via automatching; this is only valid if automatch criteria is set on the match with
        /// remaining slots for automatched players.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("pendingParticipantId")]
        public virtual string PendingParticipantId { get; set; } 

        /// <summary>The match results for the participants in the match.</summary>
        [Newtonsoft.Json.JsonPropertyAttribute("results")]
        public virtual System.Collections.Generic.IList<ParticipantResult> Results { get; set; } 

        /// <summary>The ETag of the item.</summary>
        public virtual string ETag { get; set; }
    }
}
